This commit is contained in:
NunoSempere 2024-06-18 22:46:06 -04:00
parent 239e21509f
commit 4c6fb35ac2
2 changed files with 1 additions and 1 deletions

Binary file not shown.

View File

@ -359,7 +359,7 @@ func runRepl(stack Stack, reader *bufio.Reader) Stack {
continue replForLoop
/* Parenthesis */
case len(words) == 2 && (words[0] == "*" || words[0] == "+" || words[0] == "-" || words[0] == "/") && words[1] == "(":
new_stack := runRepl(Stack{old_dist: INIT_DIST, vars: stack.vars}, reader)
new_stack := runRepl(Stack{old_dist: INIT_DIST, vars: stack.vars}, reader) // to do: think if I want to shadow variables or not (right now, variables persist, since I'm copying the map(.
stack = operateStackWithDist(stack, new_stack.old_dist, words[0])
prettyPrintDist(stack.old_dist)
case len(words) == 1 && words[0] == ")":