cofyc/argparse

可选参数的option应该怎么写?

AngusLkc opened this issue · 1 comments

比如:OPT_BOOLEAN('t', "test", &test, "test only", NULL, 0, 0),
我想命令行参数中-t带与不带参数均可正常解析能实现吗

cofyc commented

boolean 不需要参数,只是 flag 存在与否来表示 true/false
但目前实现好像带参数也行..