aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/api/goapi.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/cmd/api/goapi.go')
-rw-r--r--src/cmd/api/goapi.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/cmd/api/goapi.go b/src/cmd/api/goapi.go
index d5e66428b7..ff75f00e39 100644
--- a/src/cmd/api/goapi.go
+++ b/src/cmd/api/goapi.go
@@ -38,9 +38,7 @@ import (
// Flags
var (
- // TODO(bradfitz): once Go 1.1 comes out, allow the -c flag to take a comma-separated
- // list of files, rather than just one.
- checkFile = flag.String("c", "", "optional filename to check API against")
+ checkFile = flag.String("c", "", "optional comma-separated filename(s) to check API against")
allowNew = flag.Bool("allow_new", true, "allow API additions")
exceptFile = flag.String("except", "", "optional filename of packages that are allowed to change without triggering a failure in the tool")
nextFile = flag.String("next", "", "optional filename of tentative upcoming API features for the next release. This file can be lazily maintained. It only affects the delta warnings from the -c file printed on success.")
@@ -186,7 +184,10 @@ func main() {
return
}
- required := fileFeatures(*checkFile)
+ var required []string
+ for _, file := range strings.Split(*checkFile, ",") {
+ required = append(required, fileFeatures(file)...)
+ }
optional := fileFeatures(*nextFile)
exception := fileFeatures(*exceptFile)
fail = !compareAPI(bw, features, required, optional, exception)