XEmacs 21.2.33 "Melpomene".
[chise/xemacs-chise.git.1] / lisp / finder.el
index 8c9594a..503b7f8 100644 (file)
@@ -167,7 +167,7 @@ arguments compiles from `load-path'."
        (lambda (d)
         (mapcar
          (lambda (f) 
-           (when (not (member f processed))
+           (when (and (not (member f processed)) (file-readable-p f))
              (let (summary keystart keywords)
                (setq processed (cons f processed))
                (if (not finder-compile-keywords-quiet)
@@ -285,8 +285,12 @@ arguments compiles from `load-path'."
       found)))
 
 (defun finder-commentary (file)
-  (interactive)
-  (let* ((str (lm-commentary (finder-find-library file))))
+  "Display FILE's commentary section.
+FILE should be in a form suitable for passing to `locate-library'."
+  (interactive "sLibrary name: ")
+  (let* ((str (lm-commentary (or (finder-find-library file)
+                                (finder-find-library (concat file ".el"))
+                                (error "Can't find library %s" file)))))
     (if (null str)
        (error "Can't find any Commentary section"))
     (pop-to-buffer "*Finder*")