diff options
Diffstat (limited to 'tests/spec/glsl-es-3.00/compiler/const-initializer/from-sequence-in-function.frag')
-rw-r--r-- | tests/spec/glsl-es-3.00/compiler/const-initializer/from-sequence-in-function.frag | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/spec/glsl-es-3.00/compiler/const-initializer/from-sequence-in-function.frag b/tests/spec/glsl-es-3.00/compiler/const-initializer/from-sequence-in-function.frag new file mode 100644 index 000000000..84ed272ac --- /dev/null +++ b/tests/spec/glsl-es-3.00/compiler/const-initializer/from-sequence-in-function.frag @@ -0,0 +1,24 @@ +#version 300 es + +/* [config] + * expect_result: fail + * glsl_version: 3.00 + * [end config] + * + * Section 4.3.3 "Constant Expressions" of the OpenGL GLSL ES 3.00.4 spec + * says: + * + * "However, the sequence operator ( , ) and the assignment operators ( =, + * +=, ...) are not included in the operators that can create a constant + * expression." + */ + +precision mediump float; + +const float f = cos((1.0, 2.0)); +out vec4 fragdata; + +void main() +{ + fragdata = vec4(f); +} |