Kaydet (Commit) 9decb703 authored tarafından Guido van Rossum's avatar Guido van Rossum

In the experimental 'Scanner' feature, the group count was set wrong.

üst 42993fef
......@@ -290,8 +290,8 @@ class Scanner:
p.append(sre_parse.SubPattern(s, [
(SUBPATTERN, (len(p)+1, sre_parse.parse(phrase, flags))),
]))
s.groups = len(p)+1
p = sre_parse.SubPattern(s, [(BRANCH, (None, p))])
s.groups = len(p)
self.scanner = sre_compile.compile(p)
def scan(self, string):
result = []
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment