glslang
glslang copied to clipboard
glslangValidator compiles a uniform interface block with multiple unsized arrays without errors
#version 450
struct GTC
{
vec2 tltc;
vec2 trtc;
vec2 brtc;
vec2 bltc;
};
layout(set = 0, binding = 1) uniform _GTCBuffer
{
GTC texcoords[];
GTC gtcs[];
} _gtcBuffer;
void main()
{
}
The above code compiles successfully with glslangValidator while it must throw some errors as _GTCBuffer uniform interface block has multiple unsized arrays. As per the spec, uniform interface blocks can only support sized arrays while SSBO can support unsized arrays but still not multiple unsized arrays I guess.