예제 #1
0
        public override object VisitParentExp([NotNull] CoolParser.ParentExpContext context)
        {
            VisitExpr(context);
            dotcode += "\"" + context.GetType().Name.Substring(0, context.GetType().Name.Length - 7) + "\"[label=" + "\"()\"" + "]" + "\n";

            return(VisitChildren(context));
        }
예제 #2
0
파일: TypeVisitor.cs 프로젝트: maxblu/coolc
        public override Node VisitParentExp([NotNull] CoolParser.ParentExpContext context)
        {
            var s = VisitChildren(context);

            return(new ParentNode(context, s));
        }
 public override object VisitParentExp([NotNull] CoolParser.ParentExpContext context)
 {
     return(new Parenth((Expression)Visit(context.expresion()), GetCoord(context)));
 }
예제 #4
0
 /// <summary>
 /// Exit a parse tree produced by the <c>parentExp</c>
 /// labeled alternative in <see cref="CoolParser.expresion"/>.
 /// <para>The default implementation does nothing.</para>
 /// </summary>
 /// <param name="context">The parse tree.</param>
 public virtual void ExitParentExp([NotNull] CoolParser.ParentExpContext context)
 {
 }
 /// <summary>
 /// Visit a parse tree produced by the <c>parentExp</c>
 /// labeled alternative in <see cref="CoolParser.expresion"/>.
 /// <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 VisitParentExp([NotNull] CoolParser.ParentExpContext context)
 {
     return(VisitChildren(context));
 }
예제 #6
0
 public override bool VisitParentExp([NotNull] CoolParser.ParentExpContext context)
 {
     return(VisitChildren(context));
 }