(Created page with "'''C99''' is a past version of the C programming language standard which was ratified by ISO in 1999 and became '''ISO/IEC 9899:1999'''. The same standard was later also a...") |
(No difference)
|
Revision as of 04:57, 23 December 2013
C99 is a past version of the C programming language standard which was ratified by ISO in 1999 and became ISO/IEC 9899:1999. The same standard was later also adopted by ANSI on May 22, 2000. C99 cancels and replaces the first edition, C89, and NA1.
C99 brought the first major updates to the language in a decade. The new standard introduced restricted pointers, variable-length arrays, flexible array members, complex numbers support, type-generic math, long long int
, extended identifiers, hexadecimal floating-point constants, compound literals, designated initializers, single line, //
comments, extended integer type, the ability to mix declarations and code, variadic macros, new math functions, inline functions, boolean types, _Pragma and standard pragmas, and VA_COPY. The standard also removed implicit function declaration.
Version detection
C99 can be detected via the __STDC_VERSION__ mandatory macro which must equal 199901L
.
#if __STDC_VERSION__ >= 199901L
/* C99 support */
#endif
New headers
C99 introduced 6 new standard headers: <tgmath.h>, <stdint.h>, <stdbool.h>, <inttypes.h>, <fenv.h>, and <complex.h>.
Compiler support
Support for C99 has been a slow ongoing effort.
C99 Compiler Support | |||
Compiler Name | Support Level | Enforcement Switch | Note |
---|---|---|---|
ACK | No Support | ||
Clang | Complete | -std=c99 | No extended identifier support[1] |
GCC | Complete | -std=c99 | Supports everything[2] |
TCC | Partial | Missing lots of features[3] | |
ICC | Partial | -std=c99 | Broken extended identifier support, broken inline function support[4] |
Visual C++ | Partial | Missing type-generic math[5] |