glsl: Eliminate assumptions about size of ir_expression::operands

This may grow in the near future.
This commit is contained in:
Ian Romanick
2010-11-10 16:33:10 -08:00
parent f2616e56de
commit fc92e87b97
7 changed files with 13 additions and 7 deletions

View File

@@ -57,7 +57,7 @@ ir_expression::constant_expression_value()
if (this->type->is_error())
return NULL;
ir_constant *op[2] = { NULL, NULL };
ir_constant *op[Elements(this->operands)] = { NULL, };
ir_constant_data data;
memset(&data, 0, sizeof(data));