tools/go/analysis
Bryan C. Mills e8c45e0433 go/analysis: allow overriding V flag without code patches
In CL 149609, a file was added to
src/cmd/vendor/golang.org/x/tools/go/analysis/internal/analysisflags/patch.go
to override the behavior of the V flag for cmd/vet.

That modification causes the behavior of cmd/vet to change when a
pristine copy of x/tools is vendored in, and module-mode vendoring
will only support pristine copies (see golang/go#30240).

Instead, allow cmd/vet to override the V flag by defining its own V
flag before it invokes unitchecker.Main.

Tested manually (by patching into cmd/vendor).

Updates golang/go#30240
Updates golang/go#30241
Updates golang/go#26924
Updates golang/go#30228

Change-Id: I10e4523e1f4ede94fbfc745012dadeefef48e927
Reviewed-on: https://go-review.googlesource.com/c/162989
Run-TryBot: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Alan Donovan <adonovan@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-02-20 15:01:58 +00:00
..
analysistest go/analysis/analysistest: change error message checked in expectation 2019-02-12 19:41:11 +00:00
cmd/vet go/analysis/passes/atomicalign: add atomicalign ckecker 2019-01-21 14:31:47 +00:00
internal go/analysis: allow overriding V flag without code patches 2019-02-20 15:01:58 +00:00
multichecker go/analysis/unitchecker: a main function for vet-lite tools 2018-11-15 16:00:22 +00:00
passes go/analysis/passes/printf: add support for %w 2019-02-13 13:59:02 +00:00
singlechecker go/analysis/singlechecker: use Stderr in flag.Usage 2019-02-14 16:35:53 +00:00
unitchecker go/analysis/unitchecker: rewrite test in terms of packagestest 2019-02-13 22:38:15 +00:00
analysis.go go/{analysis,packages}: add TypesSizes 2019-01-17 19:41:23 +00:00
doc.go go/analysis: fix typos and update documentation 2019-01-11 18:03:38 +00:00
validate.go go/analysis: validate: report duplicates among analyzers (roots) 2018-10-11 19:55:00 +00:00