From d5a7f1a768aba6e86ef47e197bc430b0dc1f2c6e Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Thu, 3 Mar 2011 03:31:17 +0000 Subject: [PATCH] Don't look for methods on named pointer types. From-SVN: r170640 --- gcc/go/gofrontend/types.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/gcc/go/gofrontend/types.cc b/gcc/go/gofrontend/types.cc index 368ecae127a..cebf33ae384 100644 --- a/gcc/go/gofrontend/types.cc +++ b/gcc/go/gofrontend/types.cc @@ -7963,9 +7963,7 @@ Type::bind_field_or_method(Gogo* gogo, const Type* type, Expression* expr, if (type->deref()->is_error_type()) return Expression::make_error(location); - const Named_type* nt = type->named_type(); - if (nt == NULL) - nt = type->deref()->named_type(); + const Named_type* nt = type->deref()->named_type(); const Struct_type* st = type->deref()->struct_type(); const Interface_type* it = type->deref()->interface_type(); -- 2.30.2