| This class represents an LALR item. Each LALR item consists of
a production, a "dot" at a position within that production, and
a set of lookahead symbols (terminal). (The first two of these parts
are provide by the super class). An item is designed to represent a
configuration that the parser may be in. For example, an item of the
form:
[A ::= B * C d E , {a,b,c}]
indicates that the parser is in the middle of parsing the production
A ::= B C d E
that B has already been parsed, and that we will expect to see a lookahead
of either a, b, or c once the complete RHS of this production has been
found.
Items may initially be missing some items from their lookahead sets.
Links are maintained from each item to the set of items that would need
to be updated if symbols are added to its lookahead set. During
"lookahead propagation", we add symbols to various lookahead sets and
propagate these changes across these dependency links as needed.
See Also: java_cup.lalr_item_set See Also: java_cup.lalr_state version: last updated: 11/25/95 author: Scott Hudson |