andrey-zherikov / argparse

Parser for command-line arguments
https://andrey-zherikov.github.io/argparse/
Boost Software License 1.0
30 stars 6 forks source link

Inconsistent parsing of `bool` #123

Closed SirNickolas closed 8 months ago

SirNickolas commented 9 months ago

https://github.com/andrey-zherikov/argparse/blob/7bfd8022023cfd3cb6374c2d14c50f1895f3bc45/source/argparse/internal/valueparser.d#L149-L160

yes, y, no, and n are accepted in lower case only, but true and false are matched case-insensitively by std.conv.to. Also, when a parsing error occurs, the message only mentions true/false as allowed values.