public override Tuple <IParseTree, int> VisitChannelsSpec([NotNull] AbstractGrammarParser.ChannelsSpecContext context) { if (context.ChildCount == 0 || targetElement == context.GetChild(0)) { return(null); } if (ParseTrees.GetTerminalNodeType(targetElement) == GrammarParser.RBRACE) { return(Tuple.Create <IParseTree, int>(context, 0)); } // align to the previous element for (int i = priorSiblings.Count - 2; i >= 0; i--) { IParseTree sibling = priorSiblings[i]; // stop at the first id rule, index 0 is the CHANNELS terminal itself if (i == 1 || ParseTrees.ElementStartsLine(sibling)) { return(Tuple.Create(sibling, 0)); } } return(Tuple.Create <IParseTree, int>(context, _indentSize)); }
public override void EnterChannelsSpec([NotNull] AbstractGrammarParser.ChannelsSpecContext context) { OutlineBlock(context, "channels { ... }"); }
public override void EnterChannelsSpec([NotNull] AbstractGrammarParser.ChannelsSpecContext context) { // should we do anything here? }