aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@gcc.gnu.org>2011-05-11 19:56:39 +0000
committerIan Lance Taylor <ian@gcc.gnu.org>2011-05-11 19:56:39 +0000
commit8da1c70b570bc423fd2ea011398a69714ecd8b7a (patch)
tree34efcb6c70d4c1c9ecc1c48520a7034304ae917e /gcc
parent2d8f63a164c48a7e287987040927e40df7a97cab (diff)
downloadgcc-8da1c70b570bc423fd2ea011398a69714ecd8b7a.zip
gcc-8da1c70b570bc423fd2ea011398a69714ecd8b7a.tar.gz
gcc-8da1c70b570bc423fd2ea011398a69714ecd8b7a.tar.bz2
Permit new of a function type.
From-SVN: r173672
Diffstat (limited to 'gcc')
-rw-r--r--gcc/go/gofrontend/expressions.cc12
1 files changed, 0 insertions, 12 deletions
diff --git a/gcc/go/gofrontend/expressions.cc b/gcc/go/gofrontend/expressions.cc
index 005173b..c7b8ca0 100644
--- a/gcc/go/gofrontend/expressions.cc
+++ b/gcc/go/gofrontend/expressions.cc
@@ -10624,9 +10624,6 @@ class Allocation_expression : public Expression
do_determine_type(const Type_context*)
{ }
- void
- do_check_types(Gogo*);
-
Expression*
do_copy()
{ return new Allocation_expression(this->type_, this->location()); }
@@ -10639,15 +10636,6 @@ class Allocation_expression : public Expression
Type* type_;
};
-// Check the type of an allocation expression.
-
-void
-Allocation_expression::do_check_types(Gogo*)
-{
- if (this->type_->function_type() != NULL)
- this->report_error(_("invalid new of function type"));
-}
-
// Return a tree for an allocation expression.
tree