summaryrefslogtreecommitdiff
path: root/src/glsl/link_functions.cpp
diff options
context:
space:
mode:
authorKenneth Graunke <kenneth@whitecape.org>2010-08-30 20:42:19 -0700
committerKenneth Graunke <kenneth@whitecape.org>2010-08-30 21:04:13 -0700
commit2619b1c96feed72444499021d8a870eab1c37e00 (patch)
tree376c0518e1caac2310ff8fd75f961fb00a86bccb /src/glsl/link_functions.cpp
parentd3fa92584b109bf59dce32501eec73f8de74f42b (diff)
linker: Require an exact matching signature when looking for prototypes.
Fixes piglit test glsl-override-builtin. The linker incorrectly found the prototype for the float signature, rather than adding a new prototype with the int return type. This caused ir_calls with type int to have their callees set to the float signature, triggering an assert.
Diffstat (limited to 'src/glsl/link_functions.cpp')
-rw-r--r--src/glsl/link_functions.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/glsl/link_functions.cpp b/src/glsl/link_functions.cpp
index 6374573e61..78c8b48cf1 100644
--- a/src/glsl/link_functions.cpp
+++ b/src/glsl/link_functions.cpp
@@ -111,7 +111,7 @@ public:
f = new(linked) ir_function(name);
ir_function_signature *linked_sig =
- f->matching_signature(&callee->parameters);
+ f->exact_matching_signature(&callee->parameters);
if (linked_sig == NULL) {
linked_sig = new(linked) ir_function_signature(callee->return_type);
f->add_signature(linked_sig);