diff options
Diffstat (limited to 'src/compiler/glsl/tests/warnings/028-conditional.vert')
-rw-r--r-- | src/compiler/glsl/tests/warnings/028-conditional.vert | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/compiler/glsl/tests/warnings/028-conditional.vert b/src/compiler/glsl/tests/warnings/028-conditional.vert new file mode 100644 index 00000000000..3447f05c7da --- /dev/null +++ b/src/compiler/glsl/tests/warnings/028-conditional.vert @@ -0,0 +1,17 @@ +#version 130 + +void main() +{ + bool defined = false; + bool undefined; + int fooInt; + int definedInt = 2; + int undefinedInt; + + fooInt = defined ? definedInt : undefinedInt; + fooInt = defined ? undefinedInt : definedInt; + + fooInt = undefined ? definedInt : undefinedInt; + fooInt = undefined ? undefinedInt : definedInt; +} + |