The preprocessing language
1.4 The preprocessing language
After tokenization, the stream of tokens may simply be passed straight to the compiler's parser. However, if it contains any operations in the preprocessing language, it will be transformed first. This stage corresponds roughly to the standard's “translation phase 4” and is what most people think of as the preprocessor's job.
The preprocessing language consists of directives to be executed and macros to be expanded. Its primary capabilities are:
- Inclusion of header files. These are files of declarations that can be substituted into your program.
- Macro expansion. You can define macros, which are abbreviations for arbitrary fragments of C code. The preprocessor will replace the macros with their definitions throughout the program. Some macros are automatically defined for you.
- Conditional compilation. You can include or exclude parts of the program accordi