[plt-scheme] how to quote identifier in macro
2008/12/11 Andre Mayers <andre.mayers at usherbrooke.ca>
> (define slot-value
> (λ (slot-name objet)
> (cadr (assq (quote slot-name) objet))))
>
The (quote slot-name) is most likely redundant.
>
> (define-syntax (tata stx)
> (syntax-case stx ()
> [(_ a v (s ps ...) body ...)
> (syntax
> ; (eval
> (list 'λ '(self ps ...)
> (list* 'let (map (λ (p-attr)
> (list p-attr
> (list slot-value (quote p-attr)
> 'self)))
> a)
> '(body ...)))
>
Try
`(quote ,p-attr)
instead of
(quote p-attr)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20081211/efe38b56/attachment.html>