Front-end: enforce qualifiers that cannot appear on block declarations.
Also seems to pick up some white-space (line-ending) test differences with a prevoius checkin.
This commit is contained in:
@@ -123,3 +123,19 @@ out gl_PerVertex { // ERROR, already used and already redeclared
|
||||
highp vec4 gl_Position;
|
||||
highp vec4 t;
|
||||
};
|
||||
|
||||
smooth out smo { // ERROR, no smooth on a block
|
||||
int i;
|
||||
} smon;
|
||||
|
||||
flat out fmo { // ERROR, no flat on a block
|
||||
int i;
|
||||
} fmon;
|
||||
|
||||
centroid out cmo { // ERROR, no centroid on a block
|
||||
int i;
|
||||
} cmon;
|
||||
|
||||
invariant out imo { // ERROR, no invariant on a block
|
||||
int i;
|
||||
} imon;
|
||||
|
||||
@@ -23,7 +23,11 @@ ERROR: 0:109: 'gl_PerVertex' : block redeclaration has extra members
|
||||
ERROR: 0:119: 'gl_PointSize' : member of nameless block was not redeclared
|
||||
ERROR: 0:119: 'assign' : cannot convert from 'const float' to 'gl_PointSize highp void PointSize'
|
||||
ERROR: 0:122: 'gl_PerVertex' : can only redeclare a built-in block once, and before any use
|
||||
ERROR: 22 compilation errors. No code generated.
|
||||
ERROR: 0:127: 'flat/smooth/noperspective' : cannot use interpolation qualifiers on an interface block
|
||||
ERROR: 0:131: 'flat/smooth/noperspective' : cannot use interpolation qualifiers on an interface block
|
||||
ERROR: 0:135: 'centroid' : cannot use centroid qualifier on an interface block
|
||||
ERROR: 0:139: 'invariant' : cannot use invariant qualifier on an interface block
|
||||
ERROR: 26 compilation errors. No code generated.
|
||||
|
||||
|
||||
Shader version: 310
|
||||
@@ -225,6 +229,10 @@ ERROR: node is still EOpNull!
|
||||
0:? 'aliased' (layout(location=12 ) smooth out highp int)
|
||||
0:? 'inbinst' (in block{in highp int a})
|
||||
0:? 'anon@1' (out block{gl_Position highp 4-component vector of float Position gl_Position, })
|
||||
0:? 'smon' (smooth out block{out highp int i})
|
||||
0:? 'fmon' (flat out block{out highp int i})
|
||||
0:? 'cmon' (centroid out block{out highp int i})
|
||||
0:? 'imon' (invariant out block{out highp int i})
|
||||
0:? 'gl_VertexID' (gl_VertexId highp int VertexId)
|
||||
0:? 'gl_InstanceID' (gl_InstanceId highp int InstanceId)
|
||||
|
||||
@@ -431,6 +439,10 @@ ERROR: node is still EOpNull!
|
||||
0:? 'aliased' (layout(location=12 ) smooth out highp int)
|
||||
0:? 'inbinst' (in block{in highp int a})
|
||||
0:? 'anon@1' (out block{gl_Position highp 4-component vector of float Position gl_Position, })
|
||||
0:? 'smon' (smooth out block{out highp int i})
|
||||
0:? 'fmon' (flat out block{out highp int i})
|
||||
0:? 'cmon' (centroid out block{out highp int i})
|
||||
0:? 'imon' (invariant out block{out highp int i})
|
||||
0:? 'gl_VertexID' (gl_VertexId highp int VertexId)
|
||||
0:? 'gl_InstanceID' (gl_InstanceId highp int InstanceId)
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
Warning, version 310 is not yet complete; most version-specific features are present, but some are missing.
|
||||
ERROR: 0:9: '#error' : This should show up in pp output .
|
||||
ERROR: 0:14: '#' : invalid directive: def
|
||||
ERROR: 0:15: 'preprocessor evaluation' : undefined macro in expression not allowed in es profile Y
|
||||
ERROR: 0:21: '' : missing #endif
|
||||
ERROR: 4 compilation errors. No code generated.
|
||||
|
||||
|
||||
Warning, version 310 is not yet complete; most version-specific features are present, but some are missing.
|
||||
ERROR: 0:9: '#error' : This should show up in pp output .
|
||||
ERROR: 0:14: '#' : invalid directive: def
|
||||
ERROR: 0:15: 'preprocessor evaluation' : undefined macro in expression not allowed in es profile Y
|
||||
ERROR: 0:21: '' : missing #endif
|
||||
ERROR: 4 compilation errors. No code generated.
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
int x(){
|
||||
something that shouldnt compile;
|
||||
}
|
||||
|
||||
int x(){
|
||||
something that shouldnt compile;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user