[armedbear-ticket] [armedbear] #245: Slots of a class with a custom meta-class are reported as unbound.
armedbear
armedbear-devel at common-lisp.net
Sat Sep 1 15:20:57 UTC 2012
#245: Slots of a class with a custom meta-class are reported as unbound.
-----------------------+----------------------------------------------------
Reporter: sboukarev | Owner: ehuelsmann
Type: defect | Status: new
Priority: major | Milestone:
Component: (A)MOP | Version:
Keywords: |
-----------------------+----------------------------------------------------
{{{
(defpackage test2
(:use :cl :mop))
(in-package test2)
(defclass storable-class (standard-class)
())
(defmethod validate-superclass
((class standard-class) (superclass storable-class))
t)
(defmethod validate-superclass
((class storable-class) (superclass standard-class))
t)
;;;
(defclass identifiable ()
((id :accessor id
:initform 1))
(:metaclass storable-class))
}}}
ID slot is unbound and bound at the same time, despite having an
initform.
(describe (make-instance 'identifiable))
#<IDENTIFIABLE {181F4B24}> is an instance of #<STORABLE-CLASS IDENTIFIABLE
{1E4B2D10}>.
The following slots have :INSTANCE allocation:
ID unbound
(slot-boundp (make-instance 'identifiable) 'id)
=>
NIL
(slot-value (make-instance 'identifiable) 'id)
=>
1
--
Ticket URL: <http://trac.common-lisp.net/armedbear/ticket/245>
armedbear <http://common-lisp.net/project/armedbear>
armedbear
More information about the armedbear-ticket
mailing list