[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: question about Quasiquote
Matthias Blume writes concerning QUASIQUOTE:
I don't like the current definition of quasiquote's semantics. I
think it is not general enough and I cannot see any use of the (very
complicated) nesting level business.
Below is an example of nested QUASIQUOTE from a system for hygienic
macro expansion. The need for nested QUASIQUOTE does not arise from
EVAL, but rather from UNQUOTE and UNQUOTE-SPLICING.
(define (expand-letrec bindings body)
`((,new-lambda ,(map car bindings)
,@(map (lambda (binding)
`(,new-set! ,(car binding)
,@(map (lambda (binding) `(,new-quote unspecified)) bindings)))