From: Robert Pluim Date: Thu, 19 Jan 2023 13:34:10 +0000 (+0100) Subject: Handle after arg correctly in `keymap-set-after' X-Git-Tag: emacs-29.0.90~647 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c7e02eaa3d9af545f2acbb747da7a606fb0d1277;p=emacs.git Handle after arg correctly in `keymap-set-after' * lisp/keymap.el (keymap-set-after): AFTER: t means the same as nil, so just change it to nil. (Bug#60867) --- diff --git a/lisp/keymap.el b/lisp/keymap.el index 315eaab7560..2caaafabb94 100644 --- a/lisp/keymap.el +++ b/lisp/keymap.el @@ -186,6 +186,7 @@ a menu, so this function is not useful for non-menu keymaps." (declare (indent defun) (compiler-macro (lambda (form) (keymap--compile-check key) form))) (keymap--check key) + (when (eq after t) (setq after nil)) ; nil and t are treated the same (when after (keymap--check after)) (define-key-after keymap (key-parse key) definition