cmd/vet: -composites only checks imported types

The check has worked this way for a long time, but it has never been
well documented.

For #25453.

Change-Id: If603e53348ba51f73b2f449b943c6f97f64aa3eb
Reviewed-on: https://go-review.googlesource.com/113755
Run-TryBot: Daniel Martí <mvdan@mvdan.cc>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Rob Pike <r@golang.org>
This commit is contained in:
Daniel Martí 2018-05-18 10:45:10 +01:00
parent 226651a541
commit 8a16c71067
1 changed files with 1 additions and 1 deletions

View File

@ -18,7 +18,7 @@ var compositeWhiteList = flag.Bool("compositewhitelist", true, "use composite wh
func init() {
register("composites",
"check that composite literals used field-keyed elements",
"check that composite literals of types from imported packages use field-keyed elements",
checkUnkeyedLiteral,
compositeLit)
}