glsl: use the is_gl_identifier() helper in a couple more places

Reviewed-by: Eric Anholt <eric@anholt.net>
This commit is contained in:
Brian Paul 2015-01-02 16:19:48 -07:00
parent 83b344021b
commit a6822e3135
2 changed files with 2 additions and 2 deletions

View file

@ -706,7 +706,7 @@ ir_validate::visit(ir_variable *ir)
}
if (ir->data.mode == ir_var_uniform
&& strncmp(ir->name, "gl_", 3) == 0
&& is_gl_identifier(ir->name)
&& ir->get_state_slots() == NULL) {
printf("built-in uniform has no state\n");
ir->print();

View file

@ -52,7 +52,7 @@ optimize_dead_builtin_variables(exec_list *instructions,
&& var->data.how_declared != ir_var_declared_implicitly)
continue;
if (strncmp(var->name, "gl_", 3) != 0)
if (!is_gl_identifier(var->name))
continue;
/* gl_ModelViewProjectionMatrix and gl_Vertex are special because they