[slime-cvs] CVS slime/contrib

CVS User sboukarev sboukarev at common-lisp.net
Mon Mar 8 16:35:06 UTC 2010


Update of /project/slime/cvsroot/slime/contrib
In directory cl-net:/tmp/cvs-serv8154/contrib

Modified Files:
	ChangeLog swank-fancy-inspector.lisp 
Log Message:
* contrib/swank-fancy-inspector.lisp (all-slots-for-inspector): Sort class
names when grouping by inheritance the same way as slots are sorted.


--- /project/slime/cvsroot/slime/contrib/ChangeLog	2010/03/08 16:32:00	1.352
+++ /project/slime/cvsroot/slime/contrib/ChangeLog	2010/03/08 16:35:06	1.353
@@ -1,5 +1,10 @@
 2010-03-08  Stas Boukarev  <stassats at gmail.com>
 
+	* swank-fancy-inspector.lisp (all-slots-for-inspector): Sort class
+	names when grouping by inheritance the same way as slots are sorted.
+
+2010-03-08  Stas Boukarev  <stassats at gmail.com>
+
 	* slime-repl.el (slime-call-defun): Work also on defvar/defparameter.
 
 2010-03-07  Stas Boukarev  <stassats at gmail.com>
--- /project/slime/cvsroot/slime/contrib/swank-fancy-inspector.lisp	2010/03/07 17:04:00	1.24
+++ /project/slime/cvsroot/slime/contrib/swank-fancy-inspector.lisp	2010/03/08 16:35:06	1.25
@@ -242,15 +242,16 @@
          (sort-order
           (ensure-istate-metadata object :sort-order
                                   (box *inspector-slots-default-order*)))
+         (sort-predicate (ecase (ref sort-order)
+                           (:alphabetically #'string<)
+                           (:unsorted (constantly nil))))
          (sorted-slots (sort (copy-seq effective-slots)
-                             (ecase (ref sort-order)
-                               (:alphabetically #'string<)
-                               (:unsorted (constantly nil)))
+                             sort-predicate
                              :key #'swank-mop:slot-definition-name))
          (effective-slots
           (ecase (ref grouping-kind)
             (:all sorted-slots)
-            (:inheritance (stable-sort-by-inheritance sorted-slots class)))))
+            (:inheritance (stable-sort-by-inheritance sorted-slots class sort-predicate)))))
     `("--------------------"
       (:newline)
       " Group slots by inheritance "
@@ -372,8 +373,8 @@
                                :key #'swank-mop:slot-definition-name :test #'eq)
                        class))))
 
-(defun stable-sort-by-inheritance (slots class)
-  (stable-sort slots #'string< 
+(defun stable-sort-by-inheritance (slots class predicate)
+  (stable-sort slots predicate
                :key #'(lambda (s)
                         (class-name (slot-home-class-using-class s class)))))
 





More information about the slime-cvs mailing list