goodmami / pe

Fastest general-purpose parsing library for Python with a familiar API

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Captured choices not working with Cython machine parser

goodmami opened this issue · comments

With the cythonized machine parser, a pattern such as ~("a" / "b") will emit the matched string for "b" but not for "a". This is because the 'capture' flag is being set on the last instruction of the choice's subprogram and not after the entire choice.