mirror of
https://github.com/golang/go
synced 2024-11-26 18:06:55 -07:00
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.
|
||||
</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>
|
||||
|
||||
<p>
|
||||
|
Loading…
Reference in New Issue
Block a user