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
Compare the messages from the gc compiler and go/types (via vet):
$ go test -run=GetMod
# golang.org/x/vgo/vendor/cmd/go/internal/work
internal/work/build.go:463:70: p.Main undefined (type *load.Package has no field or method Main)
# golang.org/x/vgo/vendor/cmd/go/internal/work
internal/work/build.go:463:71: invalid operation: p (variable of type *golang.org/x/vgo/vendor/cmd/go/internal/load.Package) has no field or method Main
vet: typecheck failures
FAIL golang.org/x/vgo/vendor/cmd/go [build failed]
$
("go test" should not be showing both, but that's a different issue.)
The vet message looks like "invalid operation: p (side note)" and made me wonder "how is p an operation?" It took me a while to notice there was more text after the parenthetical that continued the original message. I think the gc message is much clearer here, and go/types should switch to it:
p.Main undefined (type *load.Package has no field or method Main)
or at least:
invalid operation: p.Main (type *load.Package has no field or method Main)
Shortening "golang.org/x/vgo/vendor/cmd/go/internal/load" to "load" also dramatically improves the usability and should probably be done too.
The text was updated successfully, but these errors were encountered:
Compare the messages from the gc compiler and go/types (via vet):
("go test" should not be showing both, but that's a different issue.)
The vet message looks like "invalid operation: p (side note)" and made me wonder "how is p an operation?" It took me a while to notice there was more text after the parenthetical that continued the original message. I think the gc message is much clearer here, and go/types should switch to it:
or at least:
Shortening "golang.org/x/vgo/vendor/cmd/go/internal/load" to "load" also dramatically improves the usability and should probably be done too.
The text was updated successfully, but these errors were encountered: