From ff7407c146b8129c2f1cc7ebe3b5771ad2f5dfdd Mon Sep 17 00:00:00 2001 From: LLLL Colonq Date: Tue, 1 Sep 2026 06:26:13 -0400 Subject: pit: Fix evaluator --- pit/test/test4.pit | 11 ++++++----- pit/test/test5.pit | 5 +++++ pit/test/test6.pit | 5 +++++ pit/test/test7.pit | 1 + 4 files changed, 17 insertions(+), 5 deletions(-) create mode 100644 pit/test/test5.pit create mode 100644 pit/test/test6.pit create mode 100644 pit/test/test7.pit (limited to 'pit/test') diff --git a/pit/test/test4.pit b/pit/test/test4.pit index 321a988..ef8e04c 100644 --- a/pit/test/test4.pit +++ b/pit/test/test4.pit @@ -1,5 +1,6 @@ -(or - (case 'foo - ('foo 1) - ('bar 2)) - 3) \ No newline at end of file +(print! + (or + (case 'baz + (foo 1) + (bar 2)) + 3)) \ No newline at end of file diff --git a/pit/test/test5.pit b/pit/test/test5.pit new file mode 100644 index 0000000..3ea3fc7 --- /dev/null +++ b/pit/test/test5.pit @@ -0,0 +1,5 @@ +(defun! foo (x) + (print! x) + (foo (+ x 1))) + +(foo 0) \ No newline at end of file diff --git a/pit/test/test6.pit b/pit/test/test6.pit new file mode 100644 index 0000000..93e5860 --- /dev/null +++ b/pit/test/test6.pit @@ -0,0 +1,5 @@ +(print! + (case 'bar + (foo 1) + (bar 2))) + \ No newline at end of file diff --git a/pit/test/test7.pit b/pit/test/test7.pit new file mode 100644 index 0000000..48d2c2c --- /dev/null +++ b/pit/test/test7.pit @@ -0,0 +1 @@ +(print! (list/map (lambda (x) (+ x 1)) '(1 2 3))) \ No newline at end of file -- cgit v1.3.1