Merge remote 'nre' into add-nre
* nre-proj/master: (132 commits) Change to options module Reweave readme Better handle errors Update documentation Change flags to inline Improve performance Add tests for empty or non-empty match Fix skipping an empty match at the end Add longer flags Fix getinfo overflows Use docweave Convert readme to RST Fix result shadowing warning Throw an exception when replacing with a nil value Fix potential buffer overflow Fix zero-length matches for multibyte characters Make splitting an empty string give 1 empty result Change endpos to inclusive Change endpos default from -1 to int.high Change capture upper bounds to inclusive ...
This commit is contained in:
commit
0d4aeec9be
47 changed files with 46616 additions and 0 deletions
7
lib/impure/nre/test/escape.nim
Normal file
7
lib/impure/nre/test/escape.nim
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
import nre, unittest
|
||||
|
||||
suite "escape strings":
|
||||
test "escape strings":
|
||||
check("123".escapeRe() == "123")
|
||||
check("[]".escapeRe() == r"\[\]")
|
||||
check("()".escapeRe() == r"\(\)")
|
||||
Loading…
Add table
Add a link
Reference in a new issue