diff options
author | marha <marha@users.sourceforge.net> | 2011-08-05 08:12:52 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2011-08-05 08:12:52 +0200 |
commit | d105412503ea250e07d3cb008f10f60e6e48bf8a (patch) | |
tree | 8601f1f1f77b22249cbfdecb20b52aa8bc69bd5a /mesalib/src/glsl/ast_to_hir.cpp | |
parent | 9b009a8bdb31d08e3d07f68416373b9aa6f85724 (diff) | |
download | vcxsrv-d105412503ea250e07d3cb008f10f60e6e48bf8a.tar.gz vcxsrv-d105412503ea250e07d3cb008f10f60e6e48bf8a.tar.bz2 vcxsrv-d105412503ea250e07d3cb008f10f60e6e48bf8a.zip |
mesa pixman git update 5 aug 2011
Diffstat (limited to 'mesalib/src/glsl/ast_to_hir.cpp')
-rw-r--r-- | mesalib/src/glsl/ast_to_hir.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/mesalib/src/glsl/ast_to_hir.cpp b/mesalib/src/glsl/ast_to_hir.cpp index c0524bf0b..7da146119 100644 --- a/mesalib/src/glsl/ast_to_hir.cpp +++ b/mesalib/src/glsl/ast_to_hir.cpp @@ -2399,12 +2399,12 @@ ast_declarator_list::hir(exec_list *instructions, decl_type = this->type->specifier->glsl_type(& type_name, state); if (this->declarations.is_empty()) { - /* The only valid case where the declaration list can be empty is when - * the declaration is setting the default precision of a built-in type - * (e.g., 'precision highp vec4;'). - */ - if (decl_type != NULL) { + /* Warn if this empty declaration is not for declaring a structure. + */ + if (this->type->specifier->structure == NULL) { + _mesa_glsl_warning(&loc, state, "empty declaration"); + } } else { _mesa_glsl_error(& loc, state, "incomplete declaration"); } |