Closed nitely closed 5 years ago
The following code throws an error:
import regex let text = "abab" var m: RegexMatch doAssert text.match(re"(a(b)){2}", m)
However, re"(ab){2}" works as expected: it captures @["ab", "ab"] for abab text.
re"(ab){2}"
@["ab", "ab"]
abab
The following code throws an error:
However,
re"(ab){2}"
works as expected: it captures@["ab", "ab"]
forabab
text.