aboutsummaryrefslogtreecommitdiffstats
path: root/src/glsl/ast_to_hir.cpp
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2011-01-07 16:53:07 -0800
committerIan Romanick <[email protected]>2011-01-13 13:35:50 -0800
commit82c4b4f88af97395a3d1b01e1998ec828cd5d305 (patch)
tree6d039092f08da726528beddb08b4cc9acd3c1f43 /src/glsl/ast_to_hir.cpp
parente1bc68b0140fef465cda26b74602aeb1cbcfdafc (diff)
glsl: Allow 'in' and 'out' when 'layout' is also available
All of the extensions that add the 'layout' keyword also enable (and required) the use of 'in' and 'out' with shader globals. This is related to (piglit) bugzilla #31804. NOTE: This is a candidate for the 7.9 and 7.10 branches.
Diffstat (limited to 'src/glsl/ast_to_hir.cpp')
-rw-r--r--src/glsl/ast_to_hir.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/glsl/ast_to_hir.cpp b/src/glsl/ast_to_hir.cpp
index a833be18f31..d70978c838b 100644
--- a/src/glsl/ast_to_hir.cpp
+++ b/src/glsl/ast_to_hir.cpp
@@ -2088,9 +2088,12 @@ ast_declarator_list::hir(exec_list *instructions,
*
* Local variables can only use the qualifier const."
*
- * This is relaxed in GLSL 1.30.
+ * This is relaxed in GLSL 1.30. It is also relaxed by any extension
+ * that adds the 'layout' keyword.
*/
- if (state->language_version < 130) {
+ if ((state->language_version < 130)
+ && !state->ARB_explicit_attrib_location_enable
+ && !state->ARB_fragment_coord_conventions_enable) {
if (this->type->qualifier.flags.q.out) {
_mesa_glsl_error(& loc, state,
"`out' qualifier in declaration of `%s' "