mirror of https://github.com/golang/go.git
doc: explain how to use "go vet -shadow"
Fixes #29260 Change-Id: I419b74d06380113f4bd32b9aeb053c3be36208d5 Reviewed-on: https://go-review.googlesource.com/c/154584 Reviewed-by: Alan Donovan <adonovan@google.com>
This commit is contained in:
parent
064842450b
commit
32b879c674
|
|
@ -93,6 +93,16 @@ Go 1.13 will require macOS 10.11 El Capitan or later.
|
||||||
vet</code> should work with all supported versions of Go.
|
vet</code> should work with all supported versions of Go.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
As part of this change, the experimental <code>-shadow</code> option
|
||||||
|
is no longer available with <code>go vet</code>. Checking for
|
||||||
|
variable shadowing may now be done using
|
||||||
|
<pre>
|
||||||
|
go install golang.org/x/tools/go/analysis/passes/shadow/cmd/shadow
|
||||||
|
go vet -vettool=$(which shadow)
|
||||||
|
</pre>
|
||||||
|
</p>
|
||||||
|
|
||||||
<h3 id="gocache">Build cache requirement</h3>
|
<h3 id="gocache">Build cache requirement</h3>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue