Extensions for GNU C compatibility
The following features are enabled by default at all language levels. For details about supported GCC features, see the GNU Compiler Collection online documentation at http://gcc.gnu.org/onlinedocs/.
| Language feature | Discussed in: |
|---|---|
| __alignof__ operator | GCC online documentation |
| __attribute__ keyword | Variable attributes, Function attributes |
| __complex__ keyword | GCC online documentation |
| __extension__ keyword | GCC online documentation |
| __imag__ and __real__ complex type operators | GCC online documentation |
| __int128 and unsigned __int128 types | GCC online documentation |
| __restrict__ keyword | GCC online documentation |
| __thread storage class specifier | The __thread storage class specifier |
| __typeof__ keyword | The typeof keyword |
| #include_next preprocessor directive | The #include_next directive |
| #warning preprocessor directive | GCC online documentation |
| Alternate keywords | GCC online documentation |
| asm inline assembly-language statements | Inline assembly statements |
| asm labels | GCC online documentation |
| Complex literal suffixes | GCC online documentation |
| Computed goto statements | GCC online documentation |
| Dollar signs in identifiers | Characters in identifiers |
| FORTIFY_SOURCE | GCC online documentation |
| Function attributes | Function attributes |
| Initialization of static variables by compound literals | Compound literal expressions |
| Labels as values | GCC online documentation |
| Postfix and unary operators on complex types (increment, decrement, and complex conjugation) | GCC online documentation |
| Statements and declarations in expressions (statement expressions) | GCC online documentation |
| Static initialization of flexible array members of aggregates | Flexible array members of structures |
| Structures with flexible array members being members of another structure | Flexible array members of structures |
| Type attributes | Type attributes |
| Variable attributes | Variable attributes |
| Variadic macro extensions | Variadic macros |
| Zero-extent arrays | GCC online documentation |
The following features are enabled
by default when you compile with the xlc invocation
command or the -qlanglvl=extc99 | extc89 | extc1x | extended options.
The following
features are enabled by default at all C++ language levels:
Some features can also be enabled or disabled
by specific compiler options, which are listed in the below table:
| Language feature | Discussed in: | Individual option controls |
|---|---|---|
| typeof keyword | The typeof keyword | GCC online documentation |
| Visibility function attribute1 | visibility | -fvisibility (-qvisibility) |
| Visibility variable attribute1 | The visibility variable attribute | -fvisibility (-qvisibility) |
Note:
|
||


