, , , , :
slot-value !
, :accessor :reader, :initarg:
(defclass foo ()
((bar :accessor foo-bar :initarg :bar)))
: getter setf foo-bar :bar to make-instance .
:
(make-instance 'foo :bar "quux")
, initargs ( ):
(let ((initargs (list :bar "quux"))) ; getting this from somewhere
(apply #'make-instance 'foo initargs))
:
(foo-bar some-foo)
setf, :
(setf (foo-bar some-foo) "wobble")
:reader :accessor, . .
slot-valuevalid for special situations in the life of an object, for example, when playing with methods for initialize-instance. This is an advanced topic.
source
share