public override ASTN VisitMethod([NotNull] MethodContext context) { MethodNode node = new MethodNode(context) { id = new IdSecundaryNode(context, context.ID().GetText()), return_type = new TypeNode(context, context.TYPE().GetText()), body_expr = VisitExpr(context.expr()) as ExprNode, paramsFormal = new List <FormalNode>() }; foreach (var formal in context.formal()) { node.paramsFormal.Add(VisitFormal(formal) as FormalNode); } return(node); }