New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmd/vet: complains about err.Error() call #4598
Labels
Milestone
Comments
An example: # cat a.go package main import ( "log" "os" ) func main() { f, err := os.Open("nosuchfile.txt") if err != nil { log.Fatal(err.Error()) } defer f.Close() } # go tool vet -v a.go Checking file a.go a.go:11:13: no args in Error call go tool vet: exit status 1 # But, strangely, works without -v # go tool vet a.go # I do not know anything about vet, but quick look shows that it assumes that any "error" function (like log.Error) must have parameters. Perhaps I am mistaken. Alex Status changed to Accepted. |
This issue was closed by revision e487ea8. Status changed to Fixed. |
This issue was closed.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
by johan.samyn:
The text was updated successfully, but these errors were encountered: