diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2021-04-26 18:40:09 -0400 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2021-04-26 18:40:09 -0400 |
commit | 7f03ee8de15df31e57fd86e193901a1cf70cc49d (patch) | |
tree | f1903f6d257703d181d57d5022031a7d8c19da4f /lisp/emacs-lisp/find-func.el | |
parent | 40c71e574ad27deee003a0850a40171750234d59 (diff) | |
download | emacs-7f03ee8de15df31e57fd86e193901a1cf70cc49d.tar.gz emacs-7f03ee8de15df31e57fd86e193901a1cf70cc49d.tar.bz2 emacs-7f03ee8de15df31e57fd86e193901a1cf70cc49d.zip |
* lisp/emacs-lisp/package.el: Fix use of `find-library-name`
That function caused a warning for a good reason.
Don't just declare it and hope it will be available.
(package--list-of-conflicts): Require `find-func` explicitly before
declaring the function. Also don't ignore all errors but only
the `file-error`s which will be emitted by `find-library-name`
in normal circumstances.
* lisp/emacs-lisp/find-func.el (find-library-name): Signal a `file-error`
Instead of a generic `error`.
Diffstat (limited to 'lisp/emacs-lisp/find-func.el')
-rw-r--r-- | lisp/emacs-lisp/find-func.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/find-func.el b/lisp/emacs-lisp/find-func.el index a0d859b834d..58876a45e19 100644 --- a/lisp/emacs-lisp/find-func.el +++ b/lisp/emacs-lisp/find-func.el @@ -208,7 +208,7 @@ LIBRARY should be a string (the name of the library)." (or find-function-source-path load-path) load-file-rep-suffixes))))) (find-library--from-load-history library) - (error "Can't find library %s" library))) + (signal 'file-error (list "Can't find library" library)))) (defun find-library--from-load-history (library) ;; In `load-history', the file may be ".elc", ".el", ".el.gz", and |