"float freq2[];" appears twice in piglit/tests/glslparsertest/shaders/CorrectFull.vert: -------------------------------- float freq2[]; while(test_float1 < 1.0); float freq2[]; -------------------------------- This causes fail: Failed to compile vertex shader piglit/tests/glslparsertest/shaders/CorrectFull.vert: Error: declaration of 'freq2' conflicts with previous declaration The GLSL spec says "Unsized arrays can be explicitly sized by an initializer at declaration time", but it doesn't say arrays can be declared as unsized twice.
I think the sequence is correct. These tests originally came from 3dlabs and the original authors of the GLSL specification. I'll talk to John K. to find the specific language in the GLSL spec.
The test is correct. Section 4.2 "Scoping" of the GLSL 1.10 document says, "A variable declared as an empty array can be re-declared as an array of the same base type."
This is fixed in glsl2.
verified with mesa master d442a01ac14382d83cdaac87d2832315ceb3e963. CorrectFull.vert still fails, but that'll be another bug.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.