tests/extmod: Add test for '-' in character class in regex.
This commit is contained in:
parent
8c7db42ee3
commit
98dd126e98
@ -48,7 +48,12 @@ m = r.match("d")
|
||||
print(m.group(0))
|
||||
m = r.match("A")
|
||||
print(m.group(0))
|
||||
print("===")
|
||||
|
||||
# '-' character within character class block
|
||||
print(re.match("[-a]+", "-a]d").group(0))
|
||||
print(re.match("[a-]+", "-a]d").group(0))
|
||||
print("===")
|
||||
|
||||
r = re.compile("o+")
|
||||
m = r.search("foobar")
|
||||
|
Loading…
x
Reference in New Issue
Block a user