]> Cypherpunks repositories - gostls13.git/commit
cmd/vet/all: work around vet printf checker deficiencies
authorJosh Bleecher Snyder <josharian@gmail.com>
Tue, 14 Feb 2017 00:11:13 +0000 (16:11 -0800)
committerJosh Bleecher Snyder <josharian@gmail.com>
Tue, 21 Feb 2017 18:41:38 +0000 (18:41 +0000)
commit8ccd007f24673adca90feb5fd23f2131b42b99d0
treefd40360e0ddd86d1190ef1640efa9071e4074161
parent35ffca31b180e6f9da6035326132f048980dc58c
cmd/vet/all: work around vet printf checker deficiencies

cmd/vet has a known deficiency in its handling of fmt.Formatters.
This causes a spurious printf error only for non-host platforms.
Since cmd/vet/all may get run on any given platform,
whitelists cannot help here.

Work around the issue by skipping printf tests entirely
for non-host platforms.

Work around the one known acceptable false positive from vet
by whitelisting the file that contains it.

Change-Id: Id74b3d4db0519cf9a670a065683715f856266e45
Reviewed-on: https://go-review.googlesource.com/36936
Reviewed-by: Rob Pike <r@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/cmd/vet/all/main.go
src/cmd/vet/all/whitelist/all.txt