aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormryouse2022-06-09 22:59:52 +0000
committermryouse2022-06-09 22:59:52 +0000
commitd8d42ddebd92b9c0211f7ae452d4c3d70c4684ec (patch)
tree581036a901df6d30e9799816706ad00fd6a4416b
parent0840eb9166dcbb090fe6b1338e9cea2a7cb53ab9 (diff)
Functions return themselves
-rw-r--r--interpreter.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/interpreter.py b/interpreter.py
index a4bba6d..67a6682 100644
--- a/interpreter.py
+++ b/interpreter.py
@@ -100,7 +100,7 @@ def interpret(exprs, env=GLOBALS):
return ret
def evaluate(expr, env):
- if isinstance(expr, Literal):
+ if isinstance(expr, Literal) or isinstance(expr, Function):
#return expr.value
return expr
elif isinstance(expr, Symbol):