logo       

How to use the simple-macros egg?: msg#00027

lisp.scheme.chicken

Subject: How to use the simple-macros egg?

For instructions on how to use the simple-macros implementation,
http://www.call-with-current-continuation.org/eggs/simple-macros.html
says merely:

> Usage:
> (require-extension simple-macros)

I tried the following example from SRFI-72:

aif.scm:

(require-extension simple-macros)

(define-syntax if-it
(lambda (x)
(syntax-case x ()
((k e1 e2 e3)
(with-syntax ((it (datum->syntax-object (syntax k) 'it)))
(syntax (let ((it e1))
(if it e2 e3))))))))

However, when I try it:

$ csi -b aif.scm
_______ _ __
/ ___/ / (_)___/ /_____ ___
/ /__/ _ \/ / __/ '_/ -_) _ \
\___/_//_/_/\__/_/\_\\__/_//_/

Version 2, Build 2 - linux-unix-gnu-x86 - [ dload ]
(c)2000-2005 Felix L. Winkelmann
; loading aif.scm ...
; loading /usr/lib/chicken/simple-macros.so ...
Error: illegal non-atomic object: ()


Any ideas?

Thank you,

Andrew


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise