mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 20:28:04 +02:00
glsl: Disallow 'in' and 'out' on globals in GLSL 1.20
Fixes piglit tests glsl-1.20/compiler/qualifiers/in-01.vert and
glsl-1.20/compiler/qualifiers/out-01.vert and bugzilla #32910.
NOTE: This is a candidate for the 7.9 and 7.10 branches. This patch
also depends on the previous two commits.
(cherry picked from commit 469ea695bb)
This commit is contained in:
parent
28d47fed61
commit
1785904c5c
1 changed files with 5 additions and 5 deletions
|
|
@ -1857,18 +1857,18 @@ ast_declarator_list::hir(exec_list *instructions,
|
|||
*
|
||||
* This is relaxed in GLSL 1.30.
|
||||
*/
|
||||
if (state->language_version < 120) {
|
||||
if (state->language_version < 130) {
|
||||
if (this->type->qualifier.out) {
|
||||
_mesa_glsl_error(& loc, state,
|
||||
"`out' qualifier in declaration of `%s' "
|
||||
"only valid for function parameters in GLSL 1.10.",
|
||||
decl->identifier);
|
||||
"only valid for function parameters in %s.",
|
||||
decl->identifier, state->version_string);
|
||||
}
|
||||
if (this->type->qualifier.in) {
|
||||
_mesa_glsl_error(& loc, state,
|
||||
"`in' qualifier in declaration of `%s' "
|
||||
"only valid for function parameters in GLSL 1.10.",
|
||||
decl->identifier);
|
||||
"only valid for function parameters in %s.",
|
||||
decl->identifier, state->version_string);
|
||||
}
|
||||
/* FINISHME: Test for other invalid qualifiers. */
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue