diff options
| author | Alan Donovan <adonovan@google.com> | 2025-12-18 12:27:11 -0500 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2026-01-15 15:10:27 -0800 |
| commit | 532e3203492ebcac67b2f3aa2a52115f49d51997 (patch) | |
| tree | ca524691be1918841d9a976c8ccd76db26c3d388 /test | |
| parent | bb7c0c717c8b3517210dce8f38cb2c91694af4e2 (diff) | |
| download | go-532e3203492ebcac67b2f3aa2a52115f49d51997.tar.xz | |
go/types,cmd/compile/internal/types2: better diagnostic for type shadowing
This change causes the "x is not a type" diagnostic to describe
x's actual kind, helping to reveal when shadowing is at work.
(The kind description could improve other errors too.)
Fixes #76877
Change-Id: Ia3484998bb384ff570c20b6792cf8461c60aa38c
Reviewed-on: https://go-review.googlesource.com/c/go/+/731180
Reviewed-by: Robert Griesemer <gri@google.com>
Auto-Submit: Alan Donovan <adonovan@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Auto-Submit: Robert Griesemer <gri@google.com>
Diffstat (limited to 'test')
| -rw-r--r-- | test/fixedbugs/issue4610.go | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/test/fixedbugs/issue4610.go b/test/fixedbugs/issue4610.go index d56c6d3e8c..8993f9882b 100644 --- a/test/fixedbugs/issue4610.go +++ b/test/fixedbugs/issue4610.go @@ -14,4 +14,3 @@ func main() { var foo bar _ = &foo{} // ERROR "is not a type|expected .;." } // GCCGO_ERROR "expected declaration" - |
