OAR

RTEMS GNU Tools On-Line Library


#else Directive

PREV UP NEXT Bookshelf The C Preprocessor

1.5.2.2: The `#else' Directive

The `#else' directive can be added to a conditional to provide alternative text to be used if the condition is false. This is what it looks like:

#if expression
text-if-true
#else /* Not expression */
text-if-false
#endif /* Not expression */

If expression is nonzero, and thus the text-if-true is active, then `#else' acts like a failing conditional and the text-if-false is ignored. Contrariwise, if the `#if' conditional fails, the text-if-false is considered included.


PREV UP NEXT Bookshelf The C Preprocessor

Packaging copyright © 1988-2000 OAR Corporation
Context copyright by each document's author. See Free Software Foundation for information.