Tests for issue 158
This commit is contained in:
parent
d2019cd12c
commit
345e344377
1 changed files with 21 additions and 0 deletions
|
|
@ -150,6 +150,27 @@ describe("parse_regex", []() {
|
|||
})
|
||||
},
|
||||
|
||||
{
|
||||
"escaped brackets",
|
||||
"\\[\\]",
|
||||
Rule::seq({
|
||||
CharacterSet{{'['}},
|
||||
CharacterSet{{']'}},
|
||||
})
|
||||
},
|
||||
|
||||
{
|
||||
"escaped brackets in choice",
|
||||
"[\\[\\]]",
|
||||
CharacterSet{{'[', ']'}}
|
||||
},
|
||||
|
||||
{
|
||||
"escaped brackets in range",
|
||||
"[\\[-\\]]",
|
||||
CharacterSet{{'[', '\\', ']'}}
|
||||
},
|
||||
|
||||
{
|
||||
"escaped periods",
|
||||
"a\\.",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue