summaryrefslogtreecommitdiffstats
path: root/src/glsl
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2013-11-27 11:22:27 -0800
committerIan Romanick <[email protected]>2013-12-06 08:06:54 -0800
commit758658850bd5ba64bf2e8c04516ea1292aedcfc3 (patch)
treea4936ae74c07faa9a426fa72da8251132f99d8d3 /src/glsl
parent453651e5212269c029e363d2227906a0ddb76204 (diff)
glsl: Don't emit empty declaration warning for a struct specifier
The intention is that things like int; will generate a warning. However, we were also accidentally emitting the same warning for things like struct Foo { int x; }; Signed-off-by: Ian Romanick <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=68838 Reviewed-by: Kenneth Graunke <[email protected]> Cc: Aras Pranckevicius <[email protected]> Cc: "9.2 10.0" <[email protected]>
Diffstat (limited to 'src/glsl')
-rw-r--r--src/glsl/ast_to_hir.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/glsl/ast_to_hir.cpp b/src/glsl/ast_to_hir.cpp
index 43cf4974557..37be1cb7562 100644
--- a/src/glsl/ast_to_hir.cpp
+++ b/src/glsl/ast_to_hir.cpp
@@ -2940,7 +2940,7 @@ ast_declarator_list::hir(exec_list *instructions,
precision_names[this->type->qualifier.precision],
type_name);
}
- } else {
+ } else if (this->type->specifier->structure == NULL) {
_mesa_glsl_warning(&loc, state, "empty declaration");
}
}