Everything

 

-strict_std [V1.06 or later] / -ansi [V1.05 or earlier]


The C source program is processed in strict compliance with the language standard.

[Specification format]

-strict_std [V1.06 or later]
-ansi       [V1.05 or earlier]

 

-

Interpretation when omitted

Compatibility with the conventional C language specifications is conferred and processing continues after warning is output. With C90 specified, some of the specifications that were added in C99 are acceptable.

[Detailed description]

-

This option selects processing of the C source program in strict compliance with the language standard which is specified with the -lang option, and errors or warnings are output for code that violates the standard.

-

When this option is specified, the macro name "__STDC__" is defined as a macro with the value 1.

-

Processing when compilation is executed in strict compliance with the language standard is as follows.

-

Compliance with C90

-

_Bool type

An error will occur.

-

long long type

An error will occur.

-

#line-number

An error will occur.

If this option is not specified, "#line-number" will be handled in the same way as "#line line-number".

-

Type conversion

Type conversions such as the assignment of a function pointer to a void pointer will cause errors.

-

Binary constants

An error will occur. [V1.06 or later]

-

Compliance with C99 [V1.06 or later]

-

#line-number

An error will occur.

If this option is not specified, "#line-number" will be handled in the same way as "#line line-number".

-

Type conversion

Type conversions such as the assignment of a function pointer to a void pointer will cause errors.

-

Binary constants

An error will occur.