From: John Wiegley Date: Mon, 30 Jul 2012 22:36:13 +0000 (-0500) Subject: Use-package now accepts function as argument X-Git-Tag: emacs-29.0.90~1306^2~15^2~469 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=8b93cee99b4ddee2acce69aff809432913b4be36;p=emacs.git Use-package now accepts function as argument --- diff --git a/lisp/use-package/use-package.el b/lisp/use-package/use-package.el index b378c03900a..26b388432a3 100644 --- a/lisp/use-package/use-package.el +++ b/lisp/use-package/use-package.el @@ -392,9 +392,12 @@ ,(if (file-name-absolute-p path) path (expand-file-name path user-emacs-directory)))) - (if (stringp pkg-load-path) - (list pkg-load-path) - pkg-load-path)) + (cond ((stringp pkg-load-path) + (list pkg-load-path)) + ((functionp pkg-load-path) + (funcall pkg-load-path)) + (t + pkg-load-path))) (when byte-compile-current-file ,@defines-eval