flag: export commandLine, the previously internal default FlagSet
s/commandLine/CommandLine/g
Fixes #4209.
R=golang-dev, dsymonds, bradfitz
CC=golang-dev
https://golang.org/cl/12587043
diff --git a/src/pkg/flag/export_test.go b/src/pkg/flag/export_test.go
index 7b19080..56cda58 100644
--- a/src/pkg/flag/export_test.go
+++ b/src/pkg/flag/export_test.go
@@ -12,11 +12,6 @@
// After calling ResetForTesting, parse errors in flag handling will not
// exit the program.
func ResetForTesting(usage func()) {
- commandLine = NewFlagSet(os.Args[0], ContinueOnError)
+ CommandLine = NewFlagSet(os.Args[0], ContinueOnError)
Usage = usage
}
-
-// CommandLine returns the default FlagSet.
-func CommandLine() *FlagSet {
- return commandLine
-}