Our website is made possible by displaying online advertisements to our visitors.
Please consider supporting us by disabling your ad blocker.

Responsive image


C preprocessor

The C preprocessor (CPP) is a text file processor that is used with C, C++ and other programming tools. The preprocessor provides for file inclusion (often header files), macro expansion, conditional compilation, and line control. Although named in association with C and used with C, the preprocessor capabilities are not inherently tied to the C language. It can and is used to process other kinds of files.[1]

C, C++, and Objective-C compilers provide a preprocessor capability, as it is required by the definition of each language. Some compilers provide extensions and deviations from the target language standard. Some provide options to control standards compliance. For instance, the GNU C preprocessor can be made more standards compliant by supplying certain command-line flags.[2]

Features of the preprocessor are encoded in source code as directives that start with #.

Although C++ source files are often named with a .cpp extension, that is an abbreviation for "C plus plus"; not C preprocessor.

  1. ^ General-purpose text preprocessing with the C preprocessor. Featuring JavaScript
  2. ^ "The C Preprocessor: Overview". Retrieved 17 July 2016.

Previous Page Next Page