[anaphora-devel] Bug in internal-symbol-macrolet setf expander
Martin Simmons
martin at lispworks.com
Fri Jun 10 15:35:59 UTC 2011
Hi there,
The setf expander for internal-symbol-macrolet makes unwarranted assumptions
about the getter form (that it can be used with setf). Ironically, this setf
expander itself returns a form that would fail if used like that!
I'd like to propose the following definition, which I think is equivalent (it
passes the test suite at least):
(define-setf-expander internal-symbol-macrolet (binding-forms place &environment env)
(multiple-value-bind (dummies vals newvals setter getter)
(get-setf-expansion place env)
(values dummies
(substitute `(symbol-macrolet ,binding-forms it) 'it vals)
newvals
`(symbol-macrolet ,binding-forms
,setter)
`(symbol-macrolet ,binding-forms ,getter))))
--
Martin Simmons
LispWorks Ltd
http://www.lispworks.com/
More information about the anaphora-devel
mailing list