summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBrian <brian@yutani.localnet.net>2007-01-15 10:35:59 -0700
committerBrian <brian@yutani.localnet.net>2007-01-15 10:35:59 -0700
commit4f5901b265dd00fd672a1f3ea5586363176c2371 (patch)
treef39dd84ed7363294ddf3850af1fb3d5dd2efa068 /src
parent629fd78f79ae49ca4a8fc2589ee479999130e550 (diff)
fix the subassig, mulassign and divassign cases
Diffstat (limited to 'src')
-rw-r--r--src/mesa/shader/slang/slang_codegen.c15
1 files changed, 3 insertions, 12 deletions
diff --git a/src/mesa/shader/slang/slang_codegen.c b/src/mesa/shader/slang/slang_codegen.c
index 3d68bb2b63..8cf30793dd 100644
--- a/src/mesa/shader/slang/slang_codegen.c
+++ b/src/mesa/shader/slang/slang_codegen.c
@@ -1969,10 +1969,7 @@ _slang_gen_operation(slang_assemble_ctx * A, slang_operation *oper)
{
slang_ir_node *n;
assert(oper->num_children == 2);
- n = _slang_gen_function_call_name(A, "-=", oper, NULL);
- /* The result of this operation should be stored back into child[0] */
- assert(n->Children[0]->Store);
- n->Store = n->Children[0]->Store;
+ n = _slang_gen_function_call_name(A, "-=", oper, &oper->children[0]);
return n;
}
break;
@@ -1980,20 +1977,14 @@ _slang_gen_operation(slang_assemble_ctx * A, slang_operation *oper)
{
slang_ir_node *n;
assert(oper->num_children == 2);
- n = _slang_gen_function_call_name(A, "*=", oper, NULL);
- /* The result of this operation should be stored back into child[0] */
- assert(n->Children[0]->Store);
- n->Store = n->Children[0]->Store;
+ n = _slang_gen_function_call_name(A, "*=", oper, &oper->children[0]);
return n;
}
case slang_oper_divassign:
{
slang_ir_node *n;
assert(oper->num_children == 2);
- n = _slang_gen_function_call_name(A, "/=", oper, NULL);
- /* The result of this operation should be stored back into child[0] */
- assert(n->Children[0]->Store);
- n->Store = n->Children[0]->Store;
+ n = _slang_gen_function_call_name(A, "/=", oper, &oper->children[0]);
return n;
}
case slang_oper_asm: