public void VisitVarDeclaration(VarDeclarationContext context) { var ids = context.IDENTIFIER(); foreach (var id in ids) { builder.DeclareVariable(id.GetText()); } }
public static VarDeclaration ToAst(this VarDeclarationContext varDeclarationContext) { return(new VarDeclaration(varDeclarationContext.type().ToAst(), varDeclarationContext.Identifier().GetText())); }