diff options
Diffstat (limited to 'src/compiler/glsl/glcpp/tests/067-nested-ifdef-ifndef.c')
-rw-r--r-- | src/compiler/glsl/glcpp/tests/067-nested-ifdef-ifndef.c | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/src/compiler/glsl/glcpp/tests/067-nested-ifdef-ifndef.c b/src/compiler/glsl/glcpp/tests/067-nested-ifdef-ifndef.c new file mode 100644 index 00000000000..f46cce4e60a --- /dev/null +++ b/src/compiler/glsl/glcpp/tests/067-nested-ifdef-ifndef.c @@ -0,0 +1,40 @@ +#define D1 +#define D2 + +#define result success + +#ifdef U1 +#ifdef U2 +#undef result +#define result failure +#endif +#endif +result + +#ifndef D1 +#ifndef D2 +#undef result +#define result failure +#endif +#endif +result + +#undef result +#define result failure +#ifdef D1 +#ifdef D2 +#undef result +#define result success +#endif +#endif +result + +#undef result +#define result failure +#ifndef U1 +#ifndef U2 +#undef result +#define result success +#endif +#endif +result |