summaryrefslogtreecommitdiff
path: root/linker.cpp
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2010-06-23 11:37:12 -0700
committerIan Romanick <ian.d.romanick@intel.com>2010-06-23 15:20:29 -0700
commit4b6fd39c89f308a379882426c1ed3616d60c4628 (patch)
tree2c8f6f7e2e3eae5922a91c61a686457c614068fe /linker.cpp
parent02fc4b34e40f655eebc99f6502293b4d4000e0b3 (diff)
Add a virtual clone() method to ir_instruction.
This will be used by function inlining, the linker, and avoiding double usage of the LHS deref chains in ++, *=, and similar operations.
Diffstat (limited to 'linker.cpp')
-rw-r--r--linker.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/linker.cpp b/linker.cpp
index abf5371ce9..ba382fe881 100644
--- a/linker.cpp
+++ b/linker.cpp
@@ -290,7 +290,8 @@ cross_validate_uniforms(struct glsl_program *prog)
* have an initializer but a later instance does, copy the
* initializer to the version stored in the symbol table.
*/
- existing->constant_value = var->constant_value->clone();
+ existing->constant_value =
+ (ir_constant *)var->constant_value->clone(NULL);
}
} else
uniforms.add_variable(var->name, var);