Remove DUPNAMES option
It makes the rest of the implementation more complicated and is confusing anyway. The user expects a 1:1 mapping between a match and a name
This commit is contained in:
parent
c4d536f581
commit
bfba4b9983
2 changed files with 1 additions and 2 deletions
|
|
@ -15,7 +15,6 @@ let Options: Table[string, int] = {
|
||||||
"E" : pcre.DOLLAR_ENDONLY,
|
"E" : pcre.DOLLAR_ENDONLY,
|
||||||
"f" : pcre.FIRSTLINE,
|
"f" : pcre.FIRSTLINE,
|
||||||
"i" : pcre.CASELESS,
|
"i" : pcre.CASELESS,
|
||||||
"J" : pcre.DUPNAMES,
|
|
||||||
"m" : pcre.MULTILINE,
|
"m" : pcre.MULTILINE,
|
||||||
"N" : pcre.NO_AUTO_CAPTURE,
|
"N" : pcre.NO_AUTO_CAPTURE,
|
||||||
"O" : pcre.NO_AUTO_POSSESS,
|
"O" : pcre.NO_AUTO_POSSESS,
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ suite "Test NRE initialization":
|
||||||
test "correct options":
|
test "correct options":
|
||||||
expect(SyntaxError): # ValueError would be bad
|
expect(SyntaxError): # ValueError would be bad
|
||||||
discard initRegex("[0-9]+",
|
discard initRegex("[0-9]+",
|
||||||
"89?AEfiJmNOsUWXxY<any><anycrlf><cr><crlf><lf><bsr_anycrlf><bsr_unicode><js>")
|
"89?AEfimNOsUWXxY<any><anycrlf><cr><crlf><lf><bsr_anycrlf><bsr_unicode><js>")
|
||||||
|
|
||||||
test "incorrect options":
|
test "incorrect options":
|
||||||
expect(KeyError): discard initRegex("[0-9]+", "a")
|
expect(KeyError): discard initRegex("[0-9]+", "a")
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue