Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Eliminating Left Recursion in Parse::RecDescent

by ikegami (Pope)
on Jun 06, 2006 at 19:14 UTC ( #553895=note: print w/ replies, xml ) Need Help??


in reply to Eliminating Left Recursion in Parse::RecDescent

I use the {1} here to emulate the behaviour of an e match. Perhaps theres a better way, if so let me know.

Just use nothing.

expr : term expr_tail expr_tail : '+' term expr_tail |

or

expr : term expr_tail expr_tail : '+' term expr_tail |

or a comment

expr : term expr_tail expr_tail : '+' term expr_tail | # Nothing

or an empty rule

expr : term expr_tail expr_tail : '+' term expr_tail | Epsilon Epsilon :

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://553895]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (5)
As of 2016-07-29 08:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What is your favorite alternate name for a (specific) keyboard key?


















    Results (260 votes). Check out past polls.