Machine-translated by Google. Questions are authored in English.
Top

Discussion

An item in LR parsing is

  • A.a nonterminal together with its FIRST and FOLLOW sets
  • B.a production with a dot marking how much has been recognised
  • C.a token together with the attribute value carried with it
  • D.an entry of the parsing table indexed by state and symbol

Answer: B

The dot separates what the parser has already seen from what it still expects. Sets of such items become the states of the automaton that drives the parse. Constructing those sets is the mechanical heart of every LR table generator.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.