Sign in to follow this  

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

This topic is 4590 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
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

This topic is 4590 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this