Created
December 11, 2022 04:34
-
-
Save MarioAriasC/1ac810fd7148777765439a3a7e3a51e9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function evalExpressions(args: ExpressionList, env: Environment): Array<MObject | null> { | |
const evalList = [] | |
for (const argument of args!!) { | |
const evaluated = evaluateNode(argument, env) | |
if (isError(evaluated)) { | |
return [evaluated] | |
} | |
evalList.push(evaluated) | |
} | |
return evalList | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment