This is the core method called during recursive decent. It must
yield (stream, results) pairs until the matcher has exhausted all
possible matches.
To evaluate a sub-matcher it should yield the result of calling
this method on the sub-matcher:
generator = sub_matcher._match(stream_in)
try:
while True:
# evaluate the sub-matcher
(stream_out, result) = yield generator
....
# return the result from this matcher
yield (stream_out, result)
except StopIteration:
...
The implementation should be decorated with @tagged in almost all
cases.
|