projects
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0bd5f4d
)
compiler: Fix struct inheriting interface with varargs method.
author
Ian Lance Taylor
<ian@gcc.gnu.org>
Wed, 7 Mar 2012 16:06:10 +0000
(16:06 +0000)
committer
Ian Lance Taylor
<ian@gcc.gnu.org>
Wed, 7 Mar 2012 16:06:10 +0000
(16:06 +0000)
From-SVN: r185060
gcc/go/gofrontend/types.cc
patch
|
blob
|
history
diff --git
a/gcc/go/gofrontend/types.cc
b/gcc/go/gofrontend/types.cc
index 3c33a6dcd49bf06603da9c87a6478a15e169ebdf..d3a75f425d148bbd1c75cfd26bdbf03abd6a74c9 100644
(file)
--- a/
gcc/go/gofrontend/types.cc
+++ b/
gcc/go/gofrontend/types.cc
@@
-3744,8
+3744,12
@@
Function_type::copy_with_receiver(Type* receiver_type) const
go_assert(!this->is_method());
Typed_identifier* receiver = new Typed_identifier("", receiver_type,
this->location_);
- return Type::make_function_type(receiver, this->parameters_,
- this->results_, this->location_);
+ Function_type* ret = Type::make_function_type(receiver, this->parameters_,
+ this->results_,
+ this->location_);
+ if (this->is_varargs_)
+ ret->set_is_varargs();
+ return ret;
}
// Make a function type.