Next: Output Prev: Combining Sources Up: Top
Miscellaneous Preprocessor Commands
This section describes three additional preprocessor commands. They
are not very useful, but are mentioned for completeness.
The "null command" consists of a `#' followed by a Newline, with
only whitespace (including comments) in between. A null command is
understood as a preprocessor command but has no effect on the
preprocessor output. The primary significance of the existence of the
null command is that an input line consisting of just a `#' will
produce no output, rather than a line of output containing just a `#'.
Supposedly some old C programs contain such lines.
The ANSI standard specifies that the `#pragma' command has an
arbitrary, implementation-defined effect. In the GNU C preprocessor,
`#pragma' commands are not used, except for `#pragma once' (*note
Once-Only::.). However, they are left in the preprocessor output, so
they are available to the compilation pass.
The `#ident' command is supported for compatibility with certain
other systems. It is followed by a line of text. On some systems, the
text is copied into a special place in the object file; on most systems,
the text is ignored and this command has no effect. Typically `#ident'
is only used in header files supplied with those systems where it is
automatically generated by info2www