Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Eliminating Left Recursion in Parse::RecDescent

by jmcnamara (Monsignor)
on Mar 21, 2002 at 00:13 UTC ( #153173=note: print w/ replies, xml ) Need Help??


in reply to Eliminating Left Recursion in Parse::RecDescent


Left-recursion and the workaround is discussed in D. Conway's article The man(1) of descent in The Perl Journal #12. It is also available in the tutorial dir of the Parse::RecDescent distro.

See the section entitled "Left-recurse ye not!" where the following example is given.

The left-recursive:     Addition: Addition '+' Term | Term

Can be handled as follows:     Addition: (Term '+')(s?) Term

--
John.


Comment on Re: Eliminating Left Recursion in Parse::RecDescent
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (3)
As of 2016-02-07 13:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How many photographs, souvenirs, artworks, trophies or other decorative objects are displayed in your home?





    Results (252 votes), past polls