aboutsummaryrefslogtreecommitdiff
path: root/bool_func.go
diff options
context:
space:
mode:
authorGeorges Varouchas <[email protected]>2025-06-27 18:02:03 +0200
committerGeorges Varouchas <[email protected]>2025-06-27 18:03:26 +0200
commit1a4b5b2e5c7ee4a194cebc579bb34198187df73d (patch)
tree289c9ab56575327b848a6dae879737cf9b1edb4d /bool_func.go
parent4730aa0d979f34d4f7427d524b84043557ba72ef (diff)
fix discrepancy in order of arguments for Func() and BoolFunc() #433
for no good reason: the order of arguments would differ when calling pflag.BoolFuncP(...) and (*FlagSet).BoolFuncP(...) (same goes for Func() and FuncP()) in this commit: align all functions on stdlib's order fixes #433
Diffstat (limited to 'bool_func.go')
-rw-r--r--bool_func.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/bool_func.go b/bool_func.go
index 76422bf..83d77af 100644
--- a/bool_func.go
+++ b/bool_func.go
@@ -35,6 +35,6 @@ func BoolFunc(name string, usage string, fn func(string) error) {
}
// BoolFuncP is like BoolFunc, but accepts a shorthand letter that can be used after a single dash.
-func BoolFuncP(name, shorthand string, fn func(string) error, usage string) {
+func BoolFuncP(name, shorthand string, usage string, fn func(string) error) {
CommandLine.BoolFuncP(name, shorthand, usage, fn)
}