[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Lexical references in DEFMACRO
- To: edsel!sunvalleymall!eb@su-navajo.arpa
- Subject: Re: Lexical references in DEFMACRO
- From: Gregor.pa@Xerox.COM
- Date: Mon, 05 May 1986 19:25:00 -0000
- Cc: Common-Lisp@su-ai.arpa
- In-reply-to: edsel!sunvalleymall!eb@su-navajo.arpa (Eric Benson)'s message of Fri, 2 May 86 16:27:58 pdt
Another problem with having the lexical environment of a defmacro'd
macro be the null environment is that you can't "macroize for speed" the
following perfecly reasonable coding style:
(let ((unique-id "foo"))
(defun make-foo () (list unique-id () () ()))
(defun foo-p (x) (and (listp x) (eq (car x) unique-id))))
Specifically, you couldn't turn the defun of foo-p into the seemingly
obvious defmacro.