]> git.eshelyaron.com Git - emacs.git/commitdiff
Don't add autoload for existing commands
authorNicolas Richard <theonewiththeevillook@yahoo.fr>
Thu, 11 Dec 2014 07:42:53 +0000 (08:42 +0100)
committerNicolas Richard <theonewiththeevillook@yahoo.fr>
Wed, 17 Dec 2014 17:30:50 +0000 (18:30 +0100)
lisp/use-package/use-package.el

index 570044970ea114ba1547694ef29de20ffa4332c0..654ed8d02b0e067e9bbbfaf117d2e2e29ea206e2 100644 (file)
@@ -434,8 +434,10 @@ For full documentation. please see commentary.
                    (not (use-package-plist-get args :demand)))
               (let (form)
                 (mapc #'(lambda (command)
-                          (push `(autoload (function ,command)
-                                   ,name-string nil t) form))
+                          (push `(unless (fboundp (quote ,command))
+                                   (autoload (function ,command)
+                                     ,name-string nil t))
+                                form))
                       commands)
 
                 `(when ,(or predicate t)