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
If I have a package with a main.go file, declaring a package main and using "//
+build ignore", go vet fails to run in this package:
% go version
go version devel +a3c0a11b128a Sun Feb 24 21:57:16 2013 -0800 darwin/amd6
% cd $GOPATH/src/sample
% cat a.go
package sample
% cat main.go
// +build ignore
package main
func main() {
}
% go vet
vet: main.go:3:1: package main; expected sample
exit status 1
The text was updated successfully, but these errors were encountered:
Just another issue, it also ignore build constraints based on file name (please edit the
issue summary):
% cat a_linux.go
package sample
import "syscall"
var _ = syscall.TCGETS
% go vet
vet: a_linux.go:5:17: cannot refer to unexported TCGETS
exit status 1
The real issue is that TCGETS is not defined for darwin, but this should not be an
issue, because the file is named a_linux.go.
The text was updated successfully, but these errors were encountered: