diff options
Diffstat (limited to 'src/glsl/ir_import_prototypes.cpp')
-rw-r--r-- | src/glsl/ir_import_prototypes.cpp | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/src/glsl/ir_import_prototypes.cpp b/src/glsl/ir_import_prototypes.cpp index 2bdc8d9fd7..4e0b30aa90 100644 --- a/src/glsl/ir_import_prototypes.cpp +++ b/src/glsl/ir_import_prototypes.cpp @@ -82,22 +82,7 @@ public: { assert(this->function != NULL); - ir_function_signature *copy = - new(mem_ctx) ir_function_signature(ir->return_type); - - copy->is_defined = false; - copy->is_builtin = ir->is_builtin; - - /* Clone the parameter list, but NOT the body. - */ - foreach_list_const(node, &ir->parameters) { - const ir_variable *const param = (const ir_variable *) node; - - assert(const_cast<ir_variable *>(param)->as_variable() != NULL); - - ir_variable *const param_copy = param->clone(mem_ctx, NULL); - copy->parameters.push_tail(param_copy); - } + ir_function_signature *copy = ir->clone_prototype(mem_ctx, NULL); this->function->add_signature(copy); |