+(defun structure-slot-names (s-name)
+ "Given a STRUCTURE-NAME, returns a list of the slots in the structure."
+ #+allegro (class-slot-names s-name)
+ #+lispworks (structure:structure-class-slot-names
+ (find-class s-name))
+ #+(or sbcl cmu) (mapcar #'kmr-mop:slot-definition-name
+ (kmr-mop:class-slots (kmr-mop:find-class s-name)))
+ #+scl (mapcar #'kernel:dsd-name
+ (kernel:dd-slots
+ (kernel:layout-info
+ (kernel:class-layout (find-class s-name)))))
+ #+(and mcl (not openmcl))
+ (let* ((sd (gethash s-name ccl::%defstructs%))
+ (slots (if sd (ccl::sd-slots sd))))
+ (mapcar #'car (if (symbolp (caar slots)) slots (cdr slots))))
+ #-(or allegro lispworks cmu sbcl scl (and mcl (not openmcl)))
+ (declare (ignore s-name))
+ #-(or allegro lispworks cmu sbcl scl (and mcl (not openmcl)))
+ (error "structure-slot-names is not defined on this platform")
+ )