; Use defvar-keymap in define-derived-mode

* lisp/emacs-lisp/derived.el (define-derived-mode): Use defvar-keymap.
This change is for documentation purposes on macro expansion.
This commit is contained in:
Stefan Kangas 2025-03-18 00:33:32 +01:00
parent 69210eb84e
commit 5f4c905353

View file

@ -217,7 +217,7 @@ No problems result if this variable is not bound.
child)))
(unless (boundp ',map)
(put ',map 'definition-name ',child))
(with-no-warnings (defvar ,map (make-sparse-keymap)))
(with-no-warnings (defvar-keymap ,map))
(unless (get ',map 'variable-documentation)
(put ',map 'variable-documentation
,(format "Keymap for `%s'." child)))