1.0.31.5: WITH-SLOTS on THE forms
[sbcl.git] / tests / compiler.impure.lisp
index 1affc40..f410d4d 100644 (file)
                             (make-something-known-to-be-a-struct :x "X" :y "Y")
                             #\x #\y)))
     (assert (not (ctu:find-named-callees f)))))
+
+(defclass some-slot-thing ()
+  ((slot :initarg :slot)))
+(with-test (:name :with-slots-the)
+  (let ((x (make-instance 'some-slot-thing :slot "foo")))
+    (with-slots (slot) (the some-slot-thing x)
+      (assert (equal "foo" slot)))))
 \f
 ;;;; tests not in the problem domain, but of the consistency of the
 ;;;; compiler machinery itself