Raymond Toy <[EMAIL PROTECTED]> writes: >> (defmethod setslot ((foo foo) val) >> (setf (slot-value foo 'a) val)) >> >> (setslot *object* 3.5) ;; triggers a type error >> >> Can somebody provide a rationale for this ?? >> > Most likely because no got around to doing it. Plus the most > interesting/most common case is probably in a method.
Wasn't this introduced by Gerd Moellmann's PCL improvements? I remember that one of the characteristics of that change was that slot access inside a defmethod was treated specially and compiled to much faster code. (In an ideal world, this would have been an improvement of the compiler, but this was probably too hard to do.) Nicolas
