protected internal override MAst Transform() { IEnumerable <MAst> variableAssignments = from variableDeclarationExpression in VariableDeclarations let variableAssign = variableDeclarationExpression.Transform() select variableAssign; IEnumerable <MAst> functionAssignments = from functionDefinitionExpression in FunctionDefinitions let functionAssign = functionDefinitionExpression.Transform() select functionAssign; IEnumerable <MAst> letBody = functionAssignments.Union(variableAssignments).Union(new[] { Body.Transform() }); return(MAst.Block(_closure, letBody)); }
protected internal override MAst Transform() { return(MAst.Block(from expression in Body.DefaultIfEmpty(new EmptyExpression()) select expression.Transform())); }