public LL1AltBlock(OutputModelFactory factory, GrammarAST blkAST, List<CodeBlockForAlt> alts) { super(factory, blkAST, alts); this.decision = ((DecisionState)blkAST.atnState).decision; /** Lookahead for each alt 1..n */ IntervalSet[] altLookSets = factory.getGrammar().decisionLOOK.get(decision); altLook = getAltLookaheadAsStringLists(altLookSets); IntervalSet expecting = IntervalSet.or(altLookSets); // combine alt sets this.error = getThrowNoViableAlt(factory, blkAST, expecting); } }
public LL1AltBlock(OutputModelFactory factory, GrammarAST blkAST, List<CodeBlockForAlt> alts) { super(factory, blkAST, alts); this.decision = ((DecisionState)blkAST.atnState).decision; /** Lookahead for each alt 1..n */ IntervalSet[] altLookSets = factory.getGrammar().decisionLOOK.get(decision); altLook = getAltLookaheadAsStringLists(altLookSets); IntervalSet expecting = IntervalSet.or(altLookSets); // combine alt sets this.error = getThrowNoViableAlt(factory, blkAST, expecting); } }
public LL1AltBlock(OutputModelFactory factory, GrammarAST blkAST, List<CodeBlockForAlt> alts) { super(factory, blkAST, alts); this.decision = ((DecisionState)blkAST.atnState).decision; /** Lookahead for each alt 1..n */ IntervalSet[] altLookSets = factory.getGrammar().decisionLOOK.get(decision); altLook = getAltLookaheadAsStringLists(altLookSets); IntervalSet expecting = IntervalSet.or(altLookSets); // combine alt sets this.error = getThrowNoViableAlt(factory, blkAST, expecting); } }
public LL1AltBlock(OutputModelFactory factory, GrammarAST blkAST, List<CodeBlockForAlt> alts) { super(factory, blkAST, alts); this.decision = ((DecisionState)blkAST.atnState).decision; /** Lookahead for each alt 1..n */ IntervalSet[] altLookSets = factory.getGrammar().decisionLOOK.get(decision); altLook = getAltLookaheadAsStringLists(altLookSets); IntervalSet expecting = IntervalSet.or(altLookSets); // combine alt sets this.error = getThrowNoViableAlt(factory, blkAST, expecting); } }
public LL1AltBlock(OutputModelFactory factory, GrammarAST blkAST, List<CodeBlockForAlt> alts) { super(factory, blkAST, alts); this.decision = ((DecisionState)blkAST.atnState).decision; /** Lookahead for each alt 1..n */ IntervalSet[] altLookSets = factory.getGrammar().decisionLOOK.get(decision); altLook = getAltLookaheadAsStringLists(altLookSets); IntervalSet expecting = IntervalSet.or(altLookSets); // combine alt sets this.error = getThrowNoViableAlt(factory, blkAST, expecting); } }