10.3 Traditional miscellany

Here are some things to be aware of when using the traditional preprocessor.

  • Preprocessing directives are recognized only when their leading ‘#’ appears in the first column. There can be no whitespace between the beginning of the line and the ‘#’, but whitespace can follow the ‘#’.
  • A true traditional C preprocessor does not recognize ‘#error’ or ‘#pragma’, and may not recognize ‘#elif’. CPP supports all the directives in traditional mode that it supports in ISO mode, including extensions, with the exception that the effects of ‘#pragma GCC poison’ are undefined.
  • __STDC__ is not defined.
  • If you use digraphs the behavior is undefined.
  • If a line that looks like a directive appears within macro arguments, the behavior is undefined.

© Free Software Foundation
Licensed under the GNU Free Documentation License, Version 1.3.