Skip to content

Commit 31b96de

Browse files
committed
Fix buggy parsing of strings with space inside <>
1 parent 4edf043 commit 31b96de

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docopt.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ class Tokens {
468468
"("
469469
"\\S*<.*?>" // strings, but make sure to keep "< >" strings together
470470
"|"
471-
"\\S+" // string without <>
471+
"[^<>\\s]+" // string without <>
472472
")" };
473473

474474
// We do two stages of regex matching. The '[]()' and '...' are strong delimeters

0 commit comments

Comments
 (0)