klahnakoski / mo-parsing

fork of pyparsing
MIT License
3 stars 2 forks source link

Handle left recursion #20

Open klahnakoski opened 3 years ago

klahnakoski commented 3 years ago

It is probably best to rewrite the left recursive grammar, and then perform tree-rewriting for the same effect.

https://en.wikipedia.org/wiki/Left_recursion#Removing_left_recursion

klahnakoski commented 3 years ago

almost all left recursion is a side-effect of infix operator parsing. With the infix pattern declaration, this may not be needed