Yves wrote: A really excellent summary of the various classes of parser and why RecDescent doesn't quite fit in any of them. Thanks, Yves.
Only one bug in the earlier discussion (and on the PerlMonks node): Left recusion is when you have a rule that calls itself as its very first subrule. Ie: expr: expr '+' term | term When Parse::RecDescent encounters something like this it should error (its documented that it will, but I haven't checked)... It definitely does. ...as it will go into an endless loop on the 'expr' rule. Unfortunately however TheDamian hasnt implemented multi level left recursion checking... Oh, yes he has! RecDescent does a complete graph traversal looking for n-ary left-recursion loops and fails to compile the grammar if it finds any left-recursive loop involving any number of rules. It has done this since its earliest versions. Damian