Show More
@@ -361,7 +361,9 b' def stringmatcher(pattern, casesensitive' | |||||
361 | flags = remod.I |
|
361 | flags = remod.I | |
362 | regex = remod.compile(pattern, flags) |
|
362 | regex = remod.compile(pattern, flags) | |
363 | except remod.error as e: |
|
363 | except remod.error as e: | |
364 |
raise error.ParseError( |
|
364 | raise error.ParseError( | |
|
365 | _(b'invalid regular expression: %s') % forcebytestr(e) | |||
|
366 | ) | |||
365 | return kind, pattern, regex.search |
|
367 | return kind, pattern, regex.search | |
366 | elif kind == b'literal': |
|
368 | elif kind == b'literal': | |
367 | if casesensitive: |
|
369 | if casesensitive: |
@@ -1448,6 +1448,9 b' test author' | |||||
1448 | (string '(')) |
|
1448 | (string '(')) | |
1449 | hg: parse error: invalid match pattern: (unbalanced parenthesis|missing \),.*) (re) |
|
1449 | hg: parse error: invalid match pattern: (unbalanced parenthesis|missing \),.*) (re) | |
1450 | [255] |
|
1450 | [255] | |
|
1451 | $ log 'desc("re:(")' | |||
|
1452 | hg: parse error: invalid regular expression: (unbalanced parenthesis|missing \),.*) (re) | |||
|
1453 | [255] | |||
1451 | $ try 'grep("\bissue\d+")' |
|
1454 | $ try 'grep("\bissue\d+")' | |
1452 | (func |
|
1455 | (func | |
1453 | (symbol 'grep') |
|
1456 | (symbol 'grep') |
General Comments 0
You need to be logged in to leave comments.
Login now