mirror of
https://gitlab.com/embeddable-common-lisp/ecl.git
synced 2026-01-16 06:12:25 -08:00
In with-early-make-instance, only collect initialization forms from slots that are not initially unbound
This commit is contained in:
parent
864810c3a6
commit
6459061654
1 changed files with 2 additions and 1 deletions
|
|
@ -35,13 +35,14 @@
|
|||
(not (eq (getf list name 'wrong) 'wrong))))
|
||||
(loop for (name . slotd) in slots
|
||||
for initarg = (getf slotd :initarg)
|
||||
for initform = (getf slotd :initform)
|
||||
for initform = (getf slotd :initform (si::unbound))
|
||||
for initvalue = (getf key-value-pairs initarg)
|
||||
for index from 0
|
||||
do (cond ((and initarg (initializerp initarg key-value-pairs))
|
||||
(setf initform (getf key-value-pairs initarg)))
|
||||
((initializerp name key-value-pairs)
|
||||
(setf initform (getf key-value-pairs name))))
|
||||
when (si:sl-boundp initform)
|
||||
collect `(si::instance-set ,object ,index ,initform)))
|
||||
(when %class
|
||||
(si::instance-sig-set ,object))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue