/[slime]/slime/swank.lisp
ViewVC logotype

Diff of /slime/swank.lisp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.303 by heller, Tue May 31 18:37:52 2005 UTC revision 1.304 by heller, Wed Jun 1 12:27:24 2005 UTC
# Line 2930  wrapped in a list." Line 2930  wrapped in a list."
2930      (let ((y (funcall f x)))      (let ((y (funcall f x)))
2931        (and y (list y)))))        (and y (list y)))))
2932    
2933  (defun present-symbol-before-p (a b)  (defun present-symbol-before-p (x y)
2934    "Return true if A belongs before B in a printed summary of symbols.    "Return true if A belongs before B in a printed summary of symbols.
2935  Sorted alphabetically by package name and then symbol name, except  Sorted alphabetically by package name and then symbol name, except
2936  that symbols accessible in the current package go first."  that symbols accessible in the current package go first."
2937      (declare (type symbol x y))
2938    (flet ((accessible (s)    (flet ((accessible (s)
2939             (find-symbol (symbol-name s) *buffer-package*)))             (or
2940      (cond ((and (accessible a) (accessible b))              (eq (symbol-package s) *buffer-package*) ; a short-cut
2941             (string< (symbol-name a) (symbol-name b)))              ;; Test breaks on NIL for package that does not inherit it
2942            ((accessible a) t)              (eq (find-symbol (symbol-name s) *buffer-package*) s))))
2943            ((accessible b) nil)      (let ((ax (accessible x)) (ay (accessible y)))
2944            (t      (if ax
2945             (string< (package-name (symbol-package a))          (if ay
2946                      (package-name (symbol-package b)))))))              (string< (symbol-name x) (symbol-name y))
2947                t)
2948            (if ay
2949                nil
2950                (let ((px (symbol-package x))
2951                      (py (symbol-package y)))
2952                  (if (eq px py)
2953                      (string< (symbol-name x) (symbol-name y))
2954                      (string< px py))))))))
2955    
2956  (let ((regex-hash (make-hash-table :test #'equal)))  (let ((regex-hash (make-hash-table :test #'equal)))
2957    (defun compiled-regex (regex-string)    (defun compiled-regex (regex-string)

Legend:
Removed from v.1.303  
changed lines
  Added in v.1.304

  ViewVC Help
Powered by ViewVC 1.1.5