de7e2b0
Branches > main > de7e2b0 > files
Test functions with arguments
Commit: de7e2b0532438cfc6acb57cf548e41bfba4ae551
Parent: 2d3c680
1 changed file:
test.lua view file
@@ -156,9 +156,14 @@ -- Later -- teq(read_eval("(let [x 1 y 2] [x y])"), {1, 2})--- teq(read_eval("((fn [x] x) :abc)"), :abc)+teq(read_eval("((fn [x] x) :abc)"), "abc")+-- Add more arities?+teq(read_eval("((fn [x y] [x y]) [1 2])"), {1, 2})+teq(read_eval("((fn [x y z] [x y z]) [1 2 3])"), {1, 2, 3}) -- teq(read_eval("((fn []))"), nil) -- teq(read_eval("((let []))"), nil)+-- teq(read_eval("((fn [] 1 2 3))"), 3)+-- teq(read_eval("((let [] 1 2 3))"), 3) -- Feels like do could be implemented in terms of let or fn idk. -- teq(read_eval("(do)"), nil)