glslang icon indicating copy to clipboard operation
glslang copied to clipboard

ES3.0 glslang frontend didn't recognize reserved keyword. image1DShadow

Open johnkslang opened this issue 8 years ago • 1 comments

From sawato shusaku:

#version 300 es
precision mediump float;
in highp vec4 dEQP_Position;
void main()
{
	float image1DShadow = 1.0;
	gl_Position = dEQP_Position;
}

// expected behavior is compile failure.
// but glslang doesn't

keywords wrong is image1DShadow image2DShadow image1DArrayShadow image2DArrayShadow

johnkslang avatar Feb 04 '17 01:02 johnkslang

Hi , @greg-lunarg I noticed that some keywords , image1DShadow , image2DShadow , image1DArrayShadow, image2DArrayShadow , which are reserved for future at spec glsl-410, but these keywords are abondoned after glsl-410. glsang source seems not implement this feature (fillInKeywordMap function) and glsang didn't report the error at version410. So should we implement it accordind to different version ?

#version 410
precision mediump float;
in highp vec4 dEQP_Position;

void main()
{
    float image1DShadow = 1.0;
    float image2DShadow = 1.0;
    float image1DArrayShadow = 1.0;
    float image2DArrayShadow = 1.0;
    gl_Position = dEQP_Position;
}

ZhiqianXia avatar Mar 29 '21 14:03 ZhiqianXia