diff options
Diffstat (limited to 'tests/preprocessor')
| -rw-r--r-- | tests/preprocessor/if-ignore.slang | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/preprocessor/if-ignore.slang b/tests/preprocessor/if-ignore.slang new file mode 100644 index 000000000..66f065bf3 --- /dev/null +++ b/tests/preprocessor/if-ignore.slang @@ -0,0 +1,17 @@ +//TEST:SIMPLE: +// Check #if expression is ignored if outer #if/#ifndef means it is skipped + +#if 0 +BadThing thatWontCompile; +#if a + b == 27 +BadThing thatWontCompile; +#endif +BadThing thatWontCompile; +#endif + +#ifdef SOMETHING_SILLY +BadThing thatWontCompile; +#if SOMETHING_SILLY +BadThing thatWontCompile; +#endif +#endif |
