| should be inside of (…) (#87)
* `|` should be inside of `(…)` It's possible to use `(t|true|T|True)` as `truthy_pattern` but still failing `true` as a truthy under my environment :-( ``` Apple LLVM version 8.0.0 (clang-800.0.42.1) Target: x86_64-apple-darwin15.6.0 Thread model: posix InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin ```
This commit is contained in:
parent
fab3bae2ff
commit
ec9e62c2c8
@ -444,9 +444,9 @@ namespace cxxopts
|
|||||||
std::basic_regex<char> integer_pattern
|
std::basic_regex<char> integer_pattern
|
||||||
("(-)?(0x)?([1-9a-zA-Z][0-9a-zA-Z]*)|((0x)?0)");
|
("(-)?(0x)?([1-9a-zA-Z][0-9a-zA-Z]*)|((0x)?0)");
|
||||||
std::basic_regex<char> truthy_pattern
|
std::basic_regex<char> truthy_pattern
|
||||||
("t|true|T|True");
|
("(t|T)(rue)?");
|
||||||
std::basic_regex<char> falsy_pattern
|
std::basic_regex<char> falsy_pattern
|
||||||
("(f|false|F|False)?");
|
("((f|F)(alse)?)?");
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace detail
|
namespace detail
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user