summaryrefslogtreecommitdiffstats
path: root/src/glsl/glcpp/tests/098-elif-undefined.c.expected
diff options
context:
space:
mode:
authorCarl Worth <[email protected]>2012-06-08 15:00:49 -0700
committerCarl Worth <[email protected]>2012-06-26 15:20:03 -0700
commitc96b8302a398a6db27f1bb6070cdc088c7ee0fba (patch)
tree0a684b1cef15912802cc763af5e4191f98d7346e /src/glsl/glcpp/tests/098-elif-undefined.c.expected
parentb75f1d973c7b626dba567b792be5a3539855a705 (diff)
glsl: glcpp: Allow "#if undefined-macro' to evaluate to false.
A strict reading of the GLSL specification would have this be an error, but we've received reports from users who expect the preprocessor to interepret undefined macros as 0. This is the standard behavior of the rpeprocessor for C, and according to these user reports is also the behavior of other OpenGL implementations. So here's one of those cases where we can make our users happier by ignoring the specification. And it's hard to imagine users who really, really want to see an error for this case. The two affected tests cases are updated to reflect the new behavior. Signed-off-by: Carl Worth <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/glsl/glcpp/tests/098-elif-undefined.c.expected')
-rw-r--r--src/glsl/glcpp/tests/098-elif-undefined.c.expected7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/glsl/glcpp/tests/098-elif-undefined.c.expected b/src/glsl/glcpp/tests/098-elif-undefined.c.expected
index de967eac438..2af0a12690a 100644
--- a/src/glsl/glcpp/tests/098-elif-undefined.c.expected
+++ b/src/glsl/glcpp/tests/098-elif-undefined.c.expected
@@ -1,5 +1,8 @@
-0:2(22): preprocessor error: syntax error, unexpected IDENTIFIER
-0:1(7): preprocessor error: Unterminated #if
+
+
+Yes, this.
+
+