tisp

tiny lisp
git clone git://edryd.org/tisp
Log | Files | Refs | LICENSE

commit 6b97b8a6475917c3db5f9f0da3a470abb42392e9
parent a604396ad2fa4099caa02948a19804b14b0111ee
Author: Ed van Bruggen <edvb@uw.edu>
Date:   Tue,  2 Jun 2020 00:34:23 -0700

Remove var macro

Diffstat:
tibs/lib.tsp | 7+------
1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/tibs/lib.tsp b/tibs/lib.tsp @@ -71,12 +71,6 @@ ((or (void? x) (nil? x) (pair? x)) x) (else (list x)))) -(defmacro (var name eq . val) - "define new variable with given value" - `(if (= ',eq '=) - ,(list* 'define name val) - (error 'var "incorrect form"))) - (defmacro (assert expr) `(unless ,expr (error 'assert "assertion " ',expr " failed"))) @@ -180,6 +174,7 @@ x))) (define (last lst) +; recur loop ((lst lst) (n (if n (car n) 0))) (if (cdr lst) (last (cdr lst)) (car lst)))