The C and C++ languages described in this reference are based on the standards listed in Standards and specifications.
This information uses the term K&R C to refer to the C language plus the generally accepted extensions produced by Brian Kernighan and Dennis Ritchie that were in use prior to the ISO standardization of C.
With a few exceptions, almost all of the language extensions are supported when you compile using the basic invocation commands xlc (for C) and xlc++ or xlC (for C++).
The default language level for the xlc invocation command is extc99, which includes all of the features introduced by the C99 standard, and most of the IBM extensions described in this information. For a complete listing of the C extensions and various methods for enabling them, see The IBM XL C language extensions.
The language level for the xlC or xlc++ invocation command is extended, which includes most of the IBM extensions described in this information, as well as many C99 features. For a complete listing of the C++ extensions and methods for enabling them, see The IBM XL C++ language extensions.
For information on the various methods for controlling the language level for compilation, see Invoking the compiler and -qlanglvl.
XL C/C++ supports the currently-implemented C++0x features as part of a continual phased release process leading towards full compliance with C++0x. To promote compatibility and portability between C99 and C++, the XL C++ compiler enables many of the C++0x features. A complete list of C++0x features supported in XL C++ is also provided in Extensions for C++0x compatibility.
The Standard C++ language specification does not include many of the features specified in the C99 language standard. To promote compatibility and portability between C99 and C++, the XL C++ compiler enables many of the C99 features that are supported by the XL C compiler. Since these features extend Standard C++, they are considered extensions to the base language. In this reference, unless the text is marked to indicate that a feature is supported in C or C99 only, C99 features also apply to C++. A complete list of C99 features supported in XL C++ is also provided in Extensions for C99 compatibility.
Certain language extensions that correspond to GNU C and GNU C++ features are implemented to facilitate portability. These include extensions to C89, C99, C++98, and Standard C++. Throughout this information, the text indicates the IBM extensions that have been implemented for compatibility with GNU C and GNU C++; a complete list of these is also provided in Extensions for GNU C compatibility and Extensions for GNU C++ compatibility.
XL C/C++ supports and extends AltiVec vector types when vector support is enabled. These language extensions exploit the SIMD and parallel processing capabilities of the PowerPC® processor, and facilitate the associated optimization techniques. The IBM implementation of the AltiVec Programming Interface specification is an extended implementation, which, for the most part, matches the syntax and semantics of the GNU C implementation. In addition to the text provided throughout this information that describes the behavior of the vector extensions, a list of the IBM extensions to the AltiVec Programming Interface is also provided in Extensions for vector processing support.