7. Use Slot-Value
(defmethod set-position ((p position) x y)
(setf (slot-value p 'x) x)
(setf (slot-value p 'y) y)
t)
(defmethod get-position ((p position))
(values (slot-value p 'x)
(slot-value p 'y)))
Previous slide
Next slide
Back to first slide
View graphic version