Jump to content
  • Advertisement
Sign in to follow this  
Lucidquiet

LL(1), LR(1), LL(k)

This topic is 4747 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I've been looking at ANTLR, JavaCC, Bison, etc. I'm trying to figure out what the LL means. I think in bison it means left to right with 1 look ahead token. But then what does LL mean. And I think the LL(k) mean k number of lookahead tokens, but I could be wrong. Does anyone know? L-

Share this post


Link to post
Share on other sites
Advertisement
Quote:
Wikipedia on LR parsers

In computer science, an LR parser is a type of bottom-up parser for context-free grammars that is very commonly used by computer programming language compilers (and other associated tools). LR parsers read their input from Left to right and produce a Rightmost derivation (hence LR, compare with LL parser). The term "LR(k) parser" is also used; here the k refers to the number of unconsumed "look ahead" input symbols that are used in making parsing decisions. Usually k is 1 and is often omitted. A context-free grammar is called LR(k) if there exists a LR(k) parser for it.


Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!