diff --git a/shape/shape.lisp b/shape/shape.lisp index 7c37ed1..2edb527 100644 --- a/shape/shape.lisp +++ b/shape/shape.lisp @@ -44,7 +44,7 @@ (print-slots rec stream 'head 'data)) (defmethod head-fields ((rec record)) - (head-fields (get-meta (class-of rec)))) + (head-fields (meta rec))) (defun head-value (rec key) (elt (head rec) (position key (head-fields rec)))) diff --git a/storage/tracking.lisp b/storage/tracking.lisp index 822bf84..e188af7 100644 --- a/storage/tracking.lisp +++ b/storage/tracking.lisp @@ -63,9 +63,10 @@ (make-instance 'container :short-name :trk :storage st)) (defmethod initialize-instance :after ((cont container) &key &allow-other-keys) - (setf (gethash (short-name cont) *containers*) cont) - (setf (item-head-fields cont) - (shape:head-fields (shape:get-meta (item-class cont))))) + (setf (gethash (short-name cont) *containers*) cont)) + +(defun item-head-fields (cont) + (shape:head-fields (shape:get-meta (item-class cont)))) (defun make-item (cont &rest head) (make-instance (item-class cont) :head head :container cont))