aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormryouse2022-06-10 00:04:04 +0000
committermryouse2022-06-10 00:04:04 +0000
commitd7466520fd61c153509710c257b358047cd01606 (patch)
tree75781325e9c6ecfe3e4dd547b4e571a9c638c4ae
parent5da9b0bb7362be01639892acfac1c98c2b3b8b0b (diff)
bugfix: 'join' works on str, not String
-rw-r--r--interpreter.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/interpreter.py b/interpreter.py
index 299dde8..a5fab45 100644
--- a/interpreter.py
+++ b/interpreter.py
@@ -716,7 +716,7 @@ def interpretJoin(symbol, args, env):
target = evaluate(args[1], env)
if not isinstance(target, String):
raise InterpretPanic(symbol, "expects a :string as its second argument", target)
- return String(target.value.join(lst.args))
+ return String(target.value.join([a.value for a in lst.args]))
GLOBALS.register("join", Builtin(interpretJoin, 2))