diff options
author | Eric Anholt <[email protected]> | 2010-07-12 19:31:54 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2010-07-12 19:50:49 -0700 |
commit | 94da2abfd49c6b4060544986ef68d5662b1cc292 (patch) | |
tree | 014e2cbed72d5069e37e193149fa162e77310f18 /src/glsl/ir_expression_flattening.cpp | |
parent | 31a97868fc14d4c57681c35021571b4b61f29e20 (diff) |
glsl2: Flatten expressions that appear as the children of ir_return as well.
Diffstat (limited to 'src/glsl/ir_expression_flattening.cpp')
-rw-r--r-- | src/glsl/ir_expression_flattening.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/glsl/ir_expression_flattening.cpp b/src/glsl/ir_expression_flattening.cpp index 629194c1a04..66268a679d9 100644 --- a/src/glsl/ir_expression_flattening.cpp +++ b/src/glsl/ir_expression_flattening.cpp @@ -176,9 +176,7 @@ ir_expression_flattening_visitor::visit_enter(ir_call *ir) ir_visitor_status ir_expression_flattening_visitor::visit_enter(ir_return *ir) { - /* FINISHME: Why not process the return value? (Same behavior as original - * FINISHME: code.) - */ - (void) ir; - return visit_continue_with_parent; + if (ir->value) + ir->value = operand_to_temp(ir->value); + return visit_continue; } |