public override InoTypeEnum Visit(ExprListAstNode node) { InoTypeEnum type; foreach (ASTNode child in node.Children) { type = Visit(child); if (type == InoTypeEnum.@float) { return(type); } type = InoTypeEnum.undefined; } return(InoTypeEnum.@int); }
public override string Visit(ExprListAstNode node) { string exprListCode = "{ "; foreach (ASTNode child in node.Children) { if (child == node.Children[0]) { exprListCode += Visit(child); } else { exprListCode += ", " + Visit(child); } } exprListCode += " }"; return(exprListCode); }