-
Notifications
You must be signed in to change notification settings - Fork 17.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
go/types: fix method set computation if receiver is a named pointer
Per the spec, methods cannot be associated with a named pointer type. Exit early with an empty method set in this case. This matches the corresponding check in LookupFieldOrMethod; the check is not present in (lowercase) lookupFieldOrMethod because it (the check) doesn't apply to struct fields. Fixes #60634. Change-Id: Ica6ca8be6b850ea0da6f0b441fbf5b99cb0b6b17 Reviewed-on: https://go-review.googlesource.com/c/go/+/501299 Reviewed-by: Robert Griesemer <gri@google.com> Auto-Submit: Robert Griesemer <gri@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Robert Findley <rfindley@google.com> Run-TryBot: Robert Griesemer <gri@google.com>
- Loading branch information
Showing
2 changed files
with
49 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters