Allow initializers of constant values to succeed.

This regresses constFunc.frag, but that's just unexpectedly passing
because of the FINISHME just above.
This commit is contained in:
Eric Anholt
2010-03-31 15:44:38 -10:00
committed by Ian Romanick
parent 068c80cfe0
commit ac3af37d27

View File

@@ -1441,8 +1441,12 @@ ast_declarator_list::hir(exec_list *instructions,
*/
if (!rhs->type->is_error()) {
bool temp = var->read_only;
if (this->type->qualifier.constant)
var->read_only = false;
(void) do_assignment(instructions, state, lhs, rhs,
this->get_location());
var->read_only = temp;
}
}