LL1Analyzer

LL1 Analyzer

Constructors

this
this(ATN atn)
Undocumented in source.

Members

Functions

LOOK
IntervalSet LOOK(ATNState s, RuleContext ctx)

Compute set of tokens that can follow {@code s} in the ATN in the specified {@code ctx}.

LOOK
IntervalSet LOOK(ATNState s, ATNState stopState, RuleContext ctx)

Compute set of tokens that can follow {@code s} in the ATN in the specified {@code ctx}.

_LOOK
void _LOOK(ATNState s, ATNState stopState, PredictionContext ctx, IntervalSet look, Array!ATNConfig* lookBusy, Array!bool* calledRuleStack, bool seeThruPreds, bool addEOF)

Compute set of tokens that can follow {@code s} in the ATN in the specified {@code ctx}.

getDecisionLookahead
IntervalSet[] getDecisionLookahead(ATNState s)

Calculates the SLL(1) expected lookahead set for each outgoing transition if an {@link ATNState}. The returned array has one element for each outgoing transition in {@code s}. If the closure from transition <em>i</em> leads to a semantic predicate before matching a symbol, the element at index <em>i</em> of the result will be {@code null}.

Static variables

HIT_PRED
int HIT_PRED;

Special value added to the lookahead sets to indicate that we hit a predicate during analysis if {@code seeThruPreds==false}.

Variables

atn
ATN atn;
Undocumented in source.

Meta