Mesa (7.9): glsl: Remove redundant semantic check in parser
Ian Romanick
idr at kemper.freedesktop.org
Sat Feb 5 00:14:05 UTC 2011
Module: Mesa
Branch: 7.9
Commit: 6fc2c15dbd0e12ddec7bdeac28164c908b2a517e
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=6fc2c15dbd0e12ddec7bdeac28164c908b2a517e
Author: Chad Versace <chad.versace at intel.com>
Date: Sun Jan 16 21:55:01 2011 -0800
glsl: Remove redundant semantic check in parser
The removed semantic check also exists in ast_type_specifier::hir(), which
is a more natural location for it.
The check verified that precision statements are applied only to types
float and int.
(cherry picked from commit a9bf8c12ee5cad398b77b7e7767ad6ef789ce877)
---
src/glsl/glsl_parser.ypp | 6 ------
1 files changed, 0 insertions(+), 6 deletions(-)
diff --git a/src/glsl/glsl_parser.ypp b/src/glsl/glsl_parser.ypp
index ac4cdb6..3f1f050 100644
--- a/src/glsl/glsl_parser.ypp
+++ b/src/glsl/glsl_parser.ypp
@@ -704,12 +704,6 @@ declaration:
}
| PRECISION precision_qualifier type_specifier_no_prec ';'
{
- if (($3->type_specifier != ast_float)
- && ($3->type_specifier != ast_int)) {
- _mesa_glsl_error(& @3, state, "global precision qualifier can "
- "only be applied to `int' or `float'\n");
- YYERROR;
- }
$3->precision = $2;
$3->is_precision_statement = true;
$$ = $3;
More information about the mesa-commit
mailing list