As a follow-up to my PR, I will refactor the parser which consumes META codes.
It should do constant-folding on simple cases, such as [a-z -- m] or [^[^a-z]]. We do still need the OP_ECLASS code, for tricky cases that can't be folded (complex logical ops over XCLASS), but doing AND/OR operations on an OP_CLASS can be folded at compile-time.
As a follow-up to my PR, I will refactor the parser which consumes META codes.
It should do constant-folding on simple cases, such as
[a-z -- m]
or[^[^a-z]]
. We do still need the OP_ECLASS code, for tricky cases that can't be folded (complex logical ops over XCLASS), but doing AND/OR operations on an OP_CLASS can be folded at compile-time.