예제 #1
0
 protected void exitRule(ParseTreeListener listener, RuleNode r) {
   ParserRuleContext ctx = (ParserRuleContext) r.getRuleContext();
   ctx.exitRule(listener);
   listener.exitEveryRule(ctx);
   GlobalInfo info = GlobalInfo.getInstance();
   info.exitRuleSetup();
 }
예제 #2
0
파일: Parser.java 프로젝트: antlr/antlr4
 /**
  * Notify any parse listeners of an exit rule event.
  *
  * @see #addParseListener
  */
 protected void triggerExitRuleEvent() {
   // reverse order walk of listeners
   for (int i = _parseListeners.size() - 1; i >= 0; i--) {
     ParseTreeListener listener = _parseListeners.get(i);
     _ctx.exitRule(listener);
     listener.exitEveryRule(_ctx);
   }
 }
예제 #3
0
 protected <Symbol> void exitRule(ParseTreeListener<Symbol> listener, ParseTree.RuleNode r) {
   @SuppressWarnings("unchecked")
   ParserRuleContext<Symbol> ctx = (ParserRuleContext<Symbol>) r.getRuleContext();
   ctx.exitRule(listener);
   listener.exitEveryRule(ctx);
 }