You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given two packages (for convenience represented via single files both stored in the same directory):
a.go: package init b.go: package b; import "./a"
the compiler reports "cannot import package as init - init must be a func", but the go/types and types2 accept this (though they correctly don't accept a local rename to init).
…ge called "init"
Updates #43962.
Change-Id: I070153c55baec62d13ca9284f02781b8c1276844
Reviewed-on: https://go-review.googlesource.com/c/go/+/287494
Trust: Robert Griesemer <gri@golang.org>
Run-TryBot: Robert Griesemer <gri@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Findley <rfindley@google.com>
The above CL was ported to dev.regabi in https://golang.org/cl/290570 (forgot to tag this issue). I think we can close this once dev.regabi becomes master.
Given two packages (for convenience represented via single files both stored in the same directory):
a.go
:package init
b.go
:package b; import "./a"
the compiler reports "cannot import package as init - init must be a func", but the
go/types
andtypes2
accept this (though they correctly don't accept a local rename toinit
).cc: @findleyr
The text was updated successfully, but these errors were encountered: