mirror of
https://github.com/golang/go
synced 2024-11-19 08:24:41 -07:00
9065c182e3
This fix adds all packages to the renamer packages map. Renaming performs checks on each package to make sure there are no conflicts. If there are multiple packages, each package needs to be checked. The packages were being incorrectly added to the map and were all being put under a single key. Fixes golang/go#33664 Change-Id: I68466ce34ac49b700ce6d14ce0b53e2795926fa9 Reviewed-on: https://go-review.googlesource.com/c/tools/+/190399 Reviewed-by: Rebecca Stambler <rstambler@golang.org>
21 lines
279 B
Plaintext
21 lines
279 B
Plaintext
-- bar-rename --
|
|
testy.go:
|
|
package testy
|
|
|
|
type tt int //@rename("tt", "testyType")
|
|
|
|
func a() {
|
|
bar := 42 //@rename("foo", "bar")
|
|
}
|
|
|
|
-- testyType-rename --
|
|
testy.go:
|
|
package testy
|
|
|
|
type testyType int //@rename("tt", "testyType")
|
|
|
|
func a() {
|
|
foo := 42 //@rename("foo", "bar")
|
|
}
|
|
|