From: john muhl Date: Mon, 8 Jul 2024 20:54:02 +0000 (-0500) Subject: Use defvar-keymap in lua-ts-mode X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=6b404d2d2d40dd1f2f208a5d76ba942d60ab45b9;p=emacs.git Use defvar-keymap in lua-ts-mode * lisp/progmodes/lua-ts-mode.el (lua-ts-mode-map): Replace 'defvar' with 'defvar-keymap'. (Bug#73585) (cherry picked from commit bf3129d5821bb8804e486bc5d51de04846a31f12) --- diff --git a/lisp/progmodes/lua-ts-mode.el b/lisp/progmodes/lua-ts-mode.el index 06daadbc1fd..d167215326c 100644 --- a/lisp/progmodes/lua-ts-mode.el +++ b/lisp/progmodes/lua-ts-mode.el @@ -720,14 +720,12 @@ Calls REPORT-FN directly." ((buffer-live-p (process-buffer process)))) (with-current-buffer buffer (comint-write-input-ring)))) -(defvar lua-ts-mode-map - (let ((map (make-sparse-keymap "Lua"))) - (keymap-set map "C-c C-n" 'lua-ts-inferior-lua) - (keymap-set map "C-c C-c" 'lua-ts-send-buffer) - (keymap-set map "C-c C-l" 'lua-ts-send-file) - (keymap-set map "C-c C-r" 'lua-ts-send-region) - map) - "Keymap for `lua-ts-mode' buffers.") +(defvar-keymap lua-ts-mode-map + :doc "Keymap for `lua-ts-mode' buffers." + "C-c C-n" #'lua-ts-inferior-lua + "C-c C-c" #'lua-ts-send-buffer + "C-c C-l" #'lua-ts-send-file + "C-c C-r" #'lua-ts-send-region) (easy-menu-define lua-ts-mode-menu lua-ts-mode-map "Menu bar entry for `lua-ts-mode'."