public override AST_Node VisitExplicitdispatch([NotNull] CoolParser.ExplicitdispatchContext context) { AST_Expresion expr = (AST_Expresion)Visit(context.expr()); var typ = (context.TYPE() == null) ? null : new AST_Type_Node(context.TYPE(), context.TYPE().GetText());; var arg = (AST_StamentList)Visit(context.argexpr()); var id = new AST_Id(context.ID(), context.ID().GetText()); return(new AST_ExpCall(context, expr, id, typ, arg)); }
/// <summary> /// Visit a parse tree produced by the <c>explicitdispatch</c> /// labeled alternative in <see cref="CoolParser.expr"/>. /// <para> /// The default implementation returns the result of calling <see cref="AbstractParseTreeVisitor{Result}.VisitChildren(IRuleNode)"/> /// on <paramref name="context"/>. /// </para> /// </summary> /// <param name="context">The parse tree.</param> /// <return>The visitor result.</return> public virtual Result VisitExplicitdispatch([NotNull] CoolParser.ExplicitdispatchContext context) { return(VisitChildren(context)); }