From: Romain Francoise Date: Tue, 21 Nov 2006 20:06:53 +0000 (+0000) Subject: (find-library-name): Don't strip ".el" from library name (reverts change X-Git-Tag: emacs-pretest-22.0.92~571 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=fef1f0f2a53aefd5c3e44fc48c02aabb891232ba;p=emacs.git (find-library-name): Don't strip ".el" from library name (reverts change of 2005-10-25). --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index acd3fa760d2..2add6c88ba5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2006-11-21 Romain Francoise + + * emacs-lisp/find-func.el (find-library-name): Don't strip ".el" + from library name (reverts change of 2005-10-25). + 2006-11-21 Lennart Borgman * tutorial.el (tutorial--default-keys): Add newline and diff --git a/lisp/emacs-lisp/find-func.el b/lisp/emacs-lisp/find-func.el index 10a052dc97e..a51493d22ea 100644 --- a/lisp/emacs-lisp/find-func.el +++ b/lisp/emacs-lisp/find-func.el @@ -147,9 +147,9 @@ See the functions `find-function' and `find-variable'." (defun find-library-name (library) "Return the absolute file name of the Lisp source of LIBRARY." - ;; Strip off the extension to take advantage of library suffixes in - ;; the call to `locate-file'. - (if (string-match "\\.el\\(c\\(\\..*\\)?\\)?\\'" library) + ;; If the library is byte-compiled, try to find a source library by + ;; the same name. + (if (string-match "\\.el\\(c\\(\\..*\\)?\\)\\'" library) (setq library (replace-match "" t t library))) (or (locate-file library (or find-function-source-path load-path)