0

I recently discovered that I have a lot of logging messages that the formatting string and the arguments are not an exact match. It seems by default (I am using go 1.6) the compiler does not report such issues.

Can I activate such check for go compile time validation or any other static code analysis tool to detect a mismatch between formatting string and arguments?

Note golint does not seem to report such issues as well.

1 Answer 1

5

The vet command reports format string errors. The vet command is included in the Go 1.6 distribution.

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.