Subject: with-slots macroexpansion bug

From: [email-masked] (Rick Taube)
Date: Tue, 3 May 94 13:28:30 GMT+0100

theres a nasty bug in with-slots such that a slot named "function"  
gets expanded to a function object!
ie:
	 #'(SLOT-VALUE #:G969 'FUNCTION) 

instead of something like:
	(function (slot-value #G969 'function))

heres the bug:

> (pprint (macroexpand '(with-slots (foo function bar) i (print  
function))))

(LET ((#:G969 I))
 (SYMBOL-MACROLET
  ((FOO (SLOT-VALUE #:G969 'FOO)) #'(SLOT-VALUE #:G969 'FUNCTION)
   (BAR (SLOT-VALUE #:G969 'BAR))
  )
  (PRINT FUNCTION)
))

im running clisp on a next machine.

	-hkt

---

From: haible (Bruno Haible)
Date: Tue, 3 May 94 13:54:42 +0200

> 	(function (slot-value #G969 'function))

This is not a bug. You have been fooled by the fact that CLISP's printer
prints lists of the form  (FUNCTION xxx)  as  #'xxx  -
regardless whether the symbol FUNCTION is meant as a special form as a
variable name.

                    Bruno Haible
                    [email-masked]