diff options
Diffstat (limited to 'src/compiler/glsl/glcpp/tests/122-redefine-whitespace.c')
-rw-r--r-- | src/compiler/glsl/glcpp/tests/122-redefine-whitespace.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/compiler/glsl/glcpp/tests/122-redefine-whitespace.c b/src/compiler/glsl/glcpp/tests/122-redefine-whitespace.c new file mode 100644 index 0000000000..ae7ea09f67 --- /dev/null +++ b/src/compiler/glsl/glcpp/tests/122-redefine-whitespace.c @@ -0,0 +1,16 @@ +/* Original definitions. */ +#define TWO ( 1+1 ) +#define FOUR (2 + 2) +#define SIX (3 + 3) + +/* Redefinitions with whitespace in same places, but different amounts, (so no + * error). */ +#define TWO ( 1+1 ) +#define FOUR (2 + 2) +#define SIX (3/*comment is whitespace*/+ /* collapsed */ /* to */ /* one */ /* space */ 3) + +/* Redefinitions with whitespace in different places. Each of these should + * trigger an error. */ +#define TWO (1 + 1) +#define FOUR ( 2+2 ) +#define SIX (/*not*/3 + 3/*expected*/) |