From: Dmitry Gutov Date: Wed, 17 Dec 2014 01:23:07 +0000 (+0200) Subject: Speed up package--list-loaded-files a bit X-Git-Tag: emacs-25.0.90~2635^2~54 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=894a1f334895da7acb549f2a42bbd7edafc13716;p=emacs.git Speed up package--list-loaded-files a bit Fixes: debbugs:19390 * lisp/emacs-lisp/package.el (package--list-loaded-files): Don't call file-truename on load-history elements. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f28dd6d449f..035f476aa80 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2014-12-17 Dmitry Gutov + + * emacs-lisp/package.el (package--list-loaded-files): Don't call + file-truename on load-history elements (bug#19390). + 2014-12-16 Nicolas Petton * emacs-lisp/seq.el: New file. diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el index cd948ae8184..60beebd8a5f 100644 --- a/lisp/emacs-lisp/package.el +++ b/lisp/emacs-lisp/package.el @@ -559,8 +559,7 @@ Return the max version (as a string) if the package is held at a lower version." "Recursively list all files in DIR which correspond to loaded features. Returns the `file-name-sans-extension' of each file, relative to DIR, sorted by most recently loaded last." - (let* ((history (mapcar (lambda (x) (file-name-sans-extension - (file-truename (car x)))) + (let* ((history (mapcar (lambda (x) (file-name-sans-extension (car x))) load-history)) (dir (file-truename dir)) ;; List all files that have already been loaded.