X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=tests%2Fglsl%2Fidentifier_conflict.glsl;fp=tests%2Fglsl%2Fidentifier_conflict.glsl;h=3e10089b0f61899f0fd8e430174b8a092b8c15cf;hb=804b3a42b84efa8a8176f68766c016292309e09c;hp=0000000000000000000000000000000000000000;hpb=063365a2e3ee9bd8d520e7115e8c0319e3736906;p=libs%2Fgl.git diff --git a/tests/glsl/identifier_conflict.glsl b/tests/glsl/identifier_conflict.glsl new file mode 100644 index 00000000..3e10089b --- /dev/null +++ b/tests/glsl/identifier_conflict.glsl @@ -0,0 +1,31 @@ +#pragma MSP stage(vertex) +layout(location=0) in vec4 position; +out VertexOut +{ + vec2 texcoord; +} vs_out; +vec3 normal; +out VertexOut2 +{ + vec2 texcoord; + vec3 normal; +}; +vec2 texcoord; +void main() +{ + vec2 texcoord; + gl_Position = position; +} +vec2 texcoord() +{ + return vec2(0.0); +} + +/* Expected error: +:11: Multiple definition of 'normal' +:7: Previous definition is here +:13: Multiple definition of 'texcoord' +:10: Previous definition is here +:19: Multiple definition of 'texcoord' +:10: Previous definition is here +*/