C Programming Language Version History

As you know, C was originally developed by Dennis Ritchie between 1969 and 1973 at Bell Labs, and used to re-implement the Unix operating system. It has since become one of the most widely used programming languages of all time, with C compilers from various vendors available for the majority of existing computer architectures and operating systems. C has been standardized by the American National Standards Institute (ANSI) since 1989 and subsequently by the International Organization for Standardization (ISO).

Version Standard Publication Date
K&R n/a 1978-02-22
C89 ANSI X3.159-1989 1989-12-14
C90 ISO/IEC 9899:1990 1990-12-20
C95 ISO/IEC 9899/AMD1:1995 1995-03-30
C99 ISO/IEC 9899:1999 1999-12-16
C11 ISO/IEC 9899:2011 2011-12-15

K&R

In 1978, Brian Kernighan and Dennis Ritchie published the first edition of The C Programming Language. This book, known to C programmers as "K&R", served for many years as an informal specification of the language. The version of C that it describes is commonly referred to as K&R C. The second edition of the book covers the later ANSI C standard, described below.

K&R introduced several language features:

  • Standard I/O library
  • long int data type
  • unsigned int data type
  • Compound assignment operators of the form =op (such as =-) were changed to the form op= (that is, -=) to remove the semantic ambiguity created by constructs such as i=-10, which had been interpreted as i =- 10 (decrement i by 10) instead of the possibly intended i = -10 (let i be -10).

In the years following the publication of K&R C, several features were added to the language, supported by compilers from AT&T and some other vendors. These included:

  • void functions (i.e., functions with no return value)
  • functions returning struct or union types (rather than pointers)
  • assignment for struct data types
  • enumerated types

C89

In 1983, the American National Standards Institute formed a committee, X3J11, to establish a standard specification of C. The standard was completed in 1989 and ratified as ANSI X3.159-1989 "Programming Language C." This version of the language is often referred to as "ANSI C". Later on sometimes the label "C89" is used to distinguish it from C99 but using the same labelling method.

C90

The same standard as C89 was ratified by the International Organization for Standardization as ISO/IEC 9899:1990, with only formatting changes, which is sometimes referred to as C90. Therefore, the terms "C89" and "C90" refer to essentially the same language.

C95

In 1995, the ISO published an extension, called Amendment 1, for the ANSI-C standard. Its full name finally was ISO/IEC 9899/AMD1:1995 or nicknamed C95. Aside from error correction there were further changes to the language capabilities, such as:

  • Improved multi-byte and wide character support in the standard library, introducing <wchar.h> and <wctype.h> as well as multi-byte I/O
  • Addition of digraphs to the language
  • Specification of standard macros for the alternative specification of operators, e.g. and for &&
  • Specification of the standard macro __STDC_VERSION__ with value 199409L

In addition to the amendment, two technical corrigenda were published by ISO for C90:

  • ISO/IEC 9899 TCOR1 in 1995
  • ISO/IEC 9899 TCOR2 in 1996

Preprocessor Test for C95 compatibility

#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199409L
    /* C95 compatible source code. */
#elif defined(__ANSI__)
    /* C89 compatible source code. */
#endif

C99

In March 2000, ANSI adopted the ISO/IEC 9899:1999 standard. This standard is commonly referred to as C99.

Some notable additions to the previous standard include:

  • New built-in data types: long long, _Bool, _Complex, and _Imaginary
  • Several new core language features, including static array indices, designated initializers, compound literals, variable-length arrays, flexible array members, variadic macros, and restrict keyword
  • Several new library headers, including stdint.h, <tgmath.h>, fenv.h, <complex.h>
  • Improved compatibility with several C++ features, including inline functions, single-line comments, mixing declarations and code, universal character names in identifiers
  • Removed several dangerous C89 language features such as implicit function declarations and implicit int

Three technical corrigenda were published by ISO for C99:

  • ISO/IEC 9899:1999/Cor.1:2001(E)
  • ISO/IEC 9899:1999/Cor.2:2004(E)
  • ISO/IEC 9899:1999/Cor.3:2007(E)

A standard macro __STDC_VERSION__ is defined with value 199901L to indicate that C99 support is available.

C11

In 2007, work began on another revision of the C standard, informally called "C1X" until its official publication on 2011-12-15. The C standards committee adopted guidelines to limit the adoption of new features that had not been tested by existing implementations.

The C11 standard adds numerous new features to C and the library

  • Including type generic macros
  • Anonymous structures
  • Improved Unicode support
  • Atomic operations
  • Multi-threading
  • Bounds-checked functions.

It also makes some portions of the existing C99 library optional, and improves compatibility with C++.
The standard macro __STDC_VERSION__ is defined as 201112L to indicate that C11 support is available.

MORE : Difference between C and ANSI C


Discussion

Read Community Guidelines
You've successfully subscribed to Developer Insider
Great! Next, complete checkout for full access to Developer Insider
Welcome back! You've successfully signed in
Success! Your account is fully activated, you now have access to all content.