It's programming time!/C++/preprocessor directives
From Create Your Own Story
Here is the exciting list of preprocessor directives!
It does excite you, right? Yeah, me neither...but, well, they are used alot, so good for referencing.
Name | Action |
---|---|
# | Null directive specifying that no action be performed. |
#define | Defines |
#elif | Conditionally includes source text if the previous #if, #ifdef, #ifndef, or #elif test fails. |
#else | Conditionally includes source text if the previous #if, #ifdef, #ifndef, or #elif test fails. |
#endif | Ends conditional text. |
#error | Defines text for a compile-time error message. |
#if | Conditionally includes or suppresses portions of source code, depending on the result of a constant expression. |
#ifdef | Conditionally includes source text if a macro name is defined. |
#ifndef | Conditionally includes source text if a macro name is not defined. |
#include | Inserts text from another source file. |
#line | Supplies a line number for compiler messages. |
#pragma | Specifies implementation-defined instructions to the compiler. |
#undef | Removes a preprocessor macro definition. |