X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;f=sql%2Fmetaclasses.lisp;h=ae511ee71c9f6c953952f065bcb3b4dfc9cac5e3;hb=aa707c93f55554dc5447c58f24e1b3ad4c01f0b9;hp=7980e325edcf6737aefb3d2f3ec5b7e93a9db9ea;hpb=d0695ffb828519fade3aa5166236812e6144975b;p=clsql.git diff --git a/sql/metaclasses.lisp b/sql/metaclasses.lisp index 7980e32..ae511ee 100644 --- a/sql/metaclasses.lisp +++ b/sql/metaclasses.lisp @@ -167,9 +167,9 @@ (defun describe-db-layout (class) (flet ((not-db-col (col) - (not (member (nth 2 col) '(nil :base :key)))) + (not (member (nth 2 col) '(nil :base :key)))) (frob-slot (slot) - (let ((type (slot-value slot 'type))) + (let ((type (slot-definition-type slot))) (if (eq type t) (setq type nil)) (list (slot-value slot 'name) @@ -423,13 +423,15 @@ which does type checking before storing a value in a slot." (car list) list)) -(declaim (inline delistify)) +(declaim (inline delistify-dsd)) (defun delistify-dsd (list) "Some MOPs, like openmcl 0.14.2, cons attribute values in a list." (if (and (listp list) (null (cdr list))) (car list) list)) +(defvar *impl-type-attrib-name* #-clisp 'type #+clisp 'clos::$type) + (defmethod compute-effective-slot-definition ((class standard-db-class) #+kmr-normal-cesd slot-name direct-slots) @@ -442,9 +444,10 @@ which does type checking before storing a value in a slot." (null (specified-type dsd))) (setf (specified-type dsd) (slot-definition-type dsd)) - (setf (slot-value dsd 'type) - (compute-lisp-type-from-slot-specification - dsd (slot-definition-type dsd)))) + (setf #-clisp (slot-value dsd 'type) + #+clisp (slot-definition-type dsd) + (compute-lisp-type-from-slot-specification + dsd (slot-definition-type dsd)))) (let ((esd (call-next-method))) (typecase dsd