aboutsummaryrefslogtreecommitdiff
path: root/bool.go
diff options
context:
space:
mode:
authorEric Paris <[email protected]>2015-08-15 14:22:16 -0500
committerEric Paris <[email protected]>2015-08-15 14:22:16 -0500
commitccad0e1b8d442b5291ebbaa7d4f3b345a9dbfe65 (patch)
tree98409d6f5f56049df54b18a9fc577cf38dff8bae /bool.go
parentda10e08318b7b4c0105c4df757cb1f997f439f4a (diff)
parent0692da7b4fa7568c62b505a313ee44a5256ee7f4 (diff)
Merge pull request #46 from eparis/goreportcard
Fix up minor things found by goreportcard.com
Diffstat (limited to 'bool.go')
-rw-r--r--bool.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/bool.go b/bool.go
index 04c9b5a..d272e40 100644
--- a/bool.go
+++ b/bool.go
@@ -53,7 +53,7 @@ func (f *FlagSet) BoolVar(p *bool, name string, value bool, usage string) {
f.BoolVarP(p, name, "", value, usage)
}
-// Like BoolVar, but accepts a shorthand letter that can be used after a single dash.
+// BoolVarP is like BoolVar, but accepts a shorthand letter that can be used after a single dash.
func (f *FlagSet) BoolVarP(p *bool, name, shorthand string, value bool, usage string) {
flag := f.VarPF(newBoolValue(value, p), name, shorthand, usage)
flag.NoOptDefVal = "true"
@@ -65,7 +65,7 @@ func BoolVar(p *bool, name string, value bool, usage string) {
BoolVarP(p, name, "", value, usage)
}
-// Like BoolVar, but accepts a shorthand letter that can be used after a single dash.
+// BoolVarP is like BoolVar, but accepts a shorthand letter that can be used after a single dash.
func BoolVarP(p *bool, name, shorthand string, value bool, usage string) {
flag := CommandLine.VarPF(newBoolValue(value, p), name, shorthand, usage)
flag.NoOptDefVal = "true"
@@ -77,7 +77,7 @@ func (f *FlagSet) Bool(name string, value bool, usage string) *bool {
return f.BoolP(name, "", value, usage)
}
-// Like Bool, but accepts a shorthand letter that can be used after a single dash.
+// BoolP is like Bool, but accepts a shorthand letter that can be used after a single dash.
func (f *FlagSet) BoolP(name, shorthand string, value bool, usage string) *bool {
p := new(bool)
f.BoolVarP(p, name, shorthand, value, usage)
@@ -90,7 +90,7 @@ func Bool(name string, value bool, usage string) *bool {
return BoolP(name, "", value, usage)
}
-// Like Bool, but accepts a shorthand letter that can be used after a single dash.
+// BoolP is like Bool, but accepts a shorthand letter that can be used after a single dash.
func BoolP(name, shorthand string, value bool, usage string) *bool {
b := CommandLine.BoolP(name, shorthand, value, usage)
return b