source:
CIVL/mods/dev.civl.abc/examples/preproc/undef.txt
| Last change on this file was aad342c, checked in by , 3 years ago | |
|---|---|
|
|
| File size: 221 bytes | |
| Rev | Line | |
|---|---|---|
| [aad342c] | 1 | #define X |
| 2 | #define Y | |
| 3 | #undef X | |
| 4 | ||
| 5 | #ifdef X | |
| 6 | #error "X should not be defined!" | |
| 7 | #endif | |
| 8 | ||
| 9 | #ifndef Y | |
| 10 | #error "Y should be defined!" | |
| 11 | #endif | |
| 12 | ||
| 13 | /* Undefining macros which are not already defined should be a no-op...*/ | |
| 14 | #undef X | |
| 15 | #undef Z |
Note:
See TracBrowser
for help on using the repository browser.
