Compiler - LL parser


An LL(k) parser is a type of parser that build the tree in a top-down way.

The inverse approach, the LR approach build the tree from the leaves


  • is a top-down parser
  • that parses from left to right,
  • constructs a leftmost derivation of the input
  • and looks ahead k tokens when selecting between the grammar rule alternatives)

The * means any number of lookahead tokens.

LL parsers can't handle left-recursive rules.

A LL grammar is easier to understand than LR grammars.

Powered by ComboStrap