summaryrefslogtreecommitdiff
path: root/src/glsl/ast_function.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/glsl/ast_function.cpp')
-rw-r--r--src/glsl/ast_function.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/glsl/ast_function.cpp b/src/glsl/ast_function.cpp
index 73af882c53..2348bdf24f 100644
--- a/src/glsl/ast_function.cpp
+++ b/src/glsl/ast_function.cpp
@@ -1081,8 +1081,7 @@ ast_function_expression::hir(exec_list *instructions,
all_parameters_are_constant = false;
if (result != ir) {
- ir->insert_before(result);
- ir->remove();
+ ir->replace_with(result);
}
}