Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
glslang
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
glslang
Commits
69d01ead
Commit
69d01ead
authored
Dec 22, 2015
by
John Kessenich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Semantics: Catch nested types containing 'int' with non-'flat' interpolation.
parent
50e57560
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
6 deletions
+12
-6
300.frag
Test/300.frag
+1
-1
300.frag.out
Test/baseResults/300.frag.out
+2
-1
revision.h
glslang/Include/revision.h
+2
-2
ParseHelper.cpp
glslang/MachineIndependent/ParseHelper.cpp
+7
-2
No files found.
Test/300.frag
View file @
69d01ead
...
@@ -37,7 +37,7 @@ struct s {
...
@@ -37,7 +37,7 @@ struct s {
};
};
in
s
badout
;
// ERROR, can't contain a sampler
in
s
badout
;
// ERROR, can't contain a sampler
// ERROR, can't have int in struct without flat
struct
S2
{
struct
S2
{
vec3
c
;
vec3
c
;
float
f
;
float
f
;
...
...
Test/baseResults/300.frag.out
View file @
69d01ead
...
@@ -4,6 +4,7 @@ ERROR: 0:30: 'noperspective' : Reserved word.
...
@@ -4,6 +4,7 @@ ERROR: 0:30: 'noperspective' : Reserved word.
ERROR: 0:30: 'noperspective' : not supported with this profile: es
ERROR: 0:30: 'noperspective' : not supported with this profile: es
ERROR: 0:31: 'sampler2D' : sampler/image types can only be used in uniform variables or function parameters: bads
ERROR: 0:31: 'sampler2D' : sampler/image types can only be used in uniform variables or function parameters: bads
ERROR: 0:32: 'uint' : cannot apply precision statement to this type; use 'float', 'int' or a sampler type
ERROR: 0:32: 'uint' : cannot apply precision statement to this type; use 'float', 'int' or a sampler type
ERROR: 0:39: 'structure' : must be qualified as flat in
ERROR: 0:39: 'structure' : non-uniform struct contains a sampler or image: badout
ERROR: 0:39: 'structure' : non-uniform struct contains a sampler or image: badout
ERROR: 0:60: 'texel offset' : argument must be compile-time constant
ERROR: 0:60: 'texel offset' : argument must be compile-time constant
ERROR: 0:62: 'texel offset' : argument must be compile-time constant
ERROR: 0:62: 'texel offset' : argument must be compile-time constant
...
@@ -43,7 +44,7 @@ ERROR: 0:157: 'invariant' : can only apply to an output
...
@@ -43,7 +44,7 @@ ERROR: 0:157: 'invariant' : can only apply to an output
ERROR: 0:158: 'invariant' : can only apply to an output
ERROR: 0:158: 'invariant' : can only apply to an output
ERROR: 0:160: 'imageBuffer' : Reserved word.
ERROR: 0:160: 'imageBuffer' : Reserved word.
ERROR: 0:160: '' : syntax error
ERROR: 0:160: '' : syntax error
ERROR: 4
4
compilation errors. No code generated.
ERROR: 4
5
compilation errors. No code generated.
Shader version: 300
Shader version: 300
...
...
glslang/Include/revision.h
View file @
69d01ead
...
@@ -2,5 +2,5 @@
...
@@ -2,5 +2,5 @@
// For the version, it uses the latest git tag followed by the number of commits.
// For the version, it uses the latest git tag followed by the number of commits.
// For the date, it uses the current date (when then script is run).
// For the date, it uses the current date (when then script is run).
#define GLSLANG_REVISION "SPIRV99.86
4
"
#define GLSLANG_REVISION "SPIRV99.86
5
"
#define GLSLANG_DATE "2
1
-Dec-2015"
#define GLSLANG_DATE "2
2
-Dec-2015"
glslang/MachineIndependent/ParseHelper.cpp
View file @
69d01ead
...
@@ -2415,9 +2415,14 @@ void TParseContext::globalQualifierTypeCheck(const TSourceLoc& loc, const TQuali
...
@@ -2415,9 +2415,14 @@ void TParseContext::globalQualifierTypeCheck(const TSourceLoc& loc, const TQuali
return
;
return
;
}
}
if
(
publicType
.
basicType
==
EbtInt
||
publicType
.
basicType
==
EbtUint
||
publicType
.
basicType
==
EbtDouble
)
{
if
(
publicType
.
basicType
==
EbtInt
||
publicType
.
basicType
==
EbtUint
||
publicType
.
basicType
==
EbtDouble
)
profileRequires
(
loc
,
EEsProfile
,
300
,
nullptr
,
"shader input/output"
);
profileRequires
(
loc
,
EEsProfile
,
300
,
nullptr
,
"shader input/output"
);
if
(
!
qualifier
.
flat
)
{
if
(
!
qualifier
.
flat
)
{
if
(
publicType
.
basicType
==
EbtInt
||
publicType
.
basicType
==
EbtUint
||
publicType
.
basicType
==
EbtDouble
||
(
publicType
.
userDef
&&
(
publicType
.
userDef
->
containsBasicType
(
EbtInt
)
||
publicType
.
userDef
->
containsBasicType
(
EbtUint
)
||
publicType
.
userDef
->
containsBasicType
(
EbtDouble
))))
{
if
(
qualifier
.
storage
==
EvqVaryingIn
&&
language
==
EShLangFragment
)
if
(
qualifier
.
storage
==
EvqVaryingIn
&&
language
==
EShLangFragment
)
error
(
loc
,
"must be qualified as flat"
,
TType
::
getBasicString
(
publicType
.
basicType
),
GetStorageQualifierString
(
qualifier
.
storage
));
error
(
loc
,
"must be qualified as flat"
,
TType
::
getBasicString
(
publicType
.
basicType
),
GetStorageQualifierString
(
qualifier
.
storage
));
else
if
(
qualifier
.
storage
==
EvqVaryingOut
&&
language
==
EShLangVertex
&&
version
==
300
)
else
if
(
qualifier
.
storage
==
EvqVaryingOut
&&
language
==
EShLangVertex
&&
version
==
300
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment