aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/vet/main.go
diff options
context:
space:
mode:
authorKonstantin Shaposhnikov <k.shaposhnikov@gmail.com>2016-03-01 22:55:06 +0800
committerRob Pike <r@golang.org>2016-03-07 22:54:38 +0000
commitb8a2e25f55de3ab42a846c08c0002b8d88248bca (patch)
treefc20aa8711002a29c740843c76bbcc18d754ba0f /src/cmd/vet/main.go
parentbcce5bdabd0c8fba61b700aab15813800b9e9c07 (diff)
downloadgo-b8a2e25f55de3ab42a846c08c0002b8d88248bca.tar.gz
go-b8a2e25f55de3ab42a846c08c0002b8d88248bca.zip
cmd/vet: remove -test flag
-test flag is a testing only flag that enables all vet checks. It was needed because there was no way to run all vet checks in a single command invocation. However it is possible to do this now by combining -all and -shadow flags. Also a recently added -tests flag is similarly named, having both -test and -tests can be confusing. Change-Id: Ie5bacbe0bef5c8409eeace46f16141fa4e782c32 Reviewed-on: https://go-review.googlesource.com/20006 Reviewed-by: Rob Pike <r@golang.org> Run-TryBot: Rob Pike <r@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/cmd/vet/main.go')
-rw-r--r--src/cmd/vet/main.go10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/cmd/vet/main.go b/src/cmd/vet/main.go
index c401fed0b4..12000867ae 100644
--- a/src/cmd/vet/main.go
+++ b/src/cmd/vet/main.go
@@ -24,10 +24,9 @@ import (
)
var (
- verbose = flag.Bool("v", false, "verbose")
- testFlag = flag.Bool("test", false, "for testing only: sets -all and -shadow")
- tags = flag.String("tags", "", "comma-separated list of build tags to apply when parsing")
- tagList = []string{} // exploded version of tags flag; set in main
+ verbose = flag.Bool("v", false, "verbose")
+ tags = flag.String("tags", "", "comma-separated list of build tags to apply when parsing")
+ tagList = []string{} // exploded version of tags flag; set in main
)
var exitCode = 0
@@ -116,9 +115,6 @@ func (ts triState) IsBoolFlag() bool {
// vet tells whether to report errors for the named check, a flag name.
func vet(name string) bool {
- if *testFlag {
- return true
- }
return report[name].isTrue()
}