KhronosGroup/WebGL — pull request #711 by RafaelCintron (2014-09-23 15:39:01+00:00)
Title: Add test for struct nesting of variable names

This test verifies that defining a typename in a new scope when the typename is the name of a variable that hides a typename declaration succeeds for all combinations of GLSL types.

Example fragment shader is of the form:
struct S { $(outer_type) u; };
void main() {
S S; // This is legal, 'S' as a typename is defined in another scope.
{
struct S { $(inner_type) a; }; // This is legal as well, 'S' is now defined as a variable name in an ancestor scope
S newvar;
newvar.a = $(initializer);
gl_FragColor = $(fragColor);
}
}