diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/getopt.erl | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/getopt.erl b/src/getopt.erl index 25ceab5..454a96e 100644 --- a/src/getopt.erl +++ b/src/getopt.erl @@ -25,7 +25,7 @@ -define(OPT_ARG, 4). -define(OPT_HELP, 5). --define(IS_OPT_SPEC(Opt), (is_tuple(Opt) andalso (size(Opt) =:= ?OPT_HELP))). +-define(IS_OPT_SPEC(Opt), (tuple_size(Opt) =:= ?OPT_HELP)). %% Atom indicating the data type that an argument can be converted to. @@ -456,10 +456,10 @@ usage_options_reverse([{Name, Short, Long, _ArgSpec, Help} | Tail], Acc) -> case Short of % Only long form. undefined -> - [$-, $-, Long]; + [$-, $- | Long]; % Both short and long form. _ -> - [$-, Short, $,, $\s, $-, $-, Long] + [$-, Short, $,, $\s, $-, $- | Long] end end, usage_options_reverse(Tail, add_option_help(Prefix, Help, Acc)); |