summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/glsl/ir.cpp8
-rw-r--r--src/glsl/ir.h5
2 files changed, 13 insertions, 0 deletions
diff --git a/src/glsl/ir.cpp b/src/glsl/ir.cpp
index 42578425839..f3ee12ce81f 100644
--- a/src/glsl/ir.cpp
+++ b/src/glsl/ir.cpp
@@ -837,6 +837,14 @@ ir_call::get_error_instruction(void *ctx)
}
void
+ir_call::set_callee(const ir_function_signature *sig)
+{
+ assert((this->type == NULL) || (this->type == sig->return_type));
+
+ this->callee = sig;
+}
+
+void
visit_exec_list(exec_list *list, ir_visitor *visitor)
{
foreach_iter(exec_list_iterator, iter, *list) {
diff --git a/src/glsl/ir.h b/src/glsl/ir.h
index 0d5bbc20aa8..89922c6bbcd 100644
--- a/src/glsl/ir.h
+++ b/src/glsl/ir.h
@@ -695,6 +695,11 @@ public:
}
/**
+ * Set the function call target
+ */
+ void set_callee(const ir_function_signature *sig);
+
+ /**
* Generates an inline version of the function before @ir,
* returning the return value of the function.
*/