diff --git a/library/lua/3rdparty/alt_getopt.lua b/library/lua/3rdparty/alt_getopt.lua index df4f51402..f6c2c5bae 100644 --- a/library/lua/3rdparty/alt_getopt.lua +++ b/library/lua/3rdparty/alt_getopt.lua @@ -50,7 +50,7 @@ local function get_opt_map(opts) local len = #opts local options = {} - for short_opt, accept_arg in opts:gmatch('(%w)(:?)') do + for short_opt, accept_arg in opts:gmatch('([%w%?])(:?)') do options[short_opt] = #accept_arg end diff --git a/library/lua/argparse.lua b/library/lua/argparse.lua index 9b4e79a69..70b9c528e 100644 --- a/library/lua/argparse.lua +++ b/library/lua/argparse.lua @@ -79,7 +79,7 @@ end -- shortOptionName and handler are required. If the option takes an argument, -- it will be passed to the handler function. -- longOptionAlias is optional. --- hasArgument defaults to false. +-- hasArg defaults to false. -- -- example usage: --