]> git.eshelyaron.com Git - emacs.git/commitdiff
Add missing autoload cookie, and make lack of a normalizer an error
authorJohn Wiegley <johnw@newartisans.com>
Wed, 6 Dec 2017 18:20:51 +0000 (10:20 -0800)
committerJohn Wiegley <johnw@newartisans.com>
Wed, 6 Dec 2017 18:20:51 +0000 (10:20 -0800)
Fixes https://github.com/jwiegley/use-package/issues/566

lisp/use-package/use-package-bind-key.el
lisp/use-package/use-package-core.el

index 7c5d27253012cc758e10d42199045b385b174fb7..4a3d421522bc5403e78cd978441b645fc5a96d1b 100644 (file)
@@ -66,6 +66,7 @@ deferred until the prefix key sequence is pressed."
        (format "package.el %s failed to define keymap %s"
                package keymap-symbol)))))
 
+;;;###autoload
 (defun use-package-normalize-binder (name keyword args)
   (let ((arg args)
         args*)
index 7711806d1953b7c41766619365f2635172de4dda..4ab8a84a35849b77f497a9671bdd96d5e4bda5fe 100644 (file)
@@ -476,12 +476,8 @@ extending any keys already present."
            (tail (cdr xs))
            (normalizer (intern (concat "use-package-normalize/"
                                        (symbol-name keyword))))
-           (arg (cond ((functionp normalizer)
-                       (funcall normalizer name keyword args))
-                      ((= (length args) 1)
-                       (car args))
-                      (t
-                       args))))
+           (arg (and (functionp normalizer)
+                     (funcall normalizer name keyword args))))
       (if (memq keyword use-package-keywords)
           (progn
             (setq plist (use-package-normalize-plist