Commit a4e59635 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(double-setup): Only copy `key-translation-map' if it is a keymap.

parent a11a197b
...@@ -145,7 +145,9 @@ but not `C-u X' or `ESC X' since the X is not the prefix key." ...@@ -145,7 +145,9 @@ but not `C-u X' or `ESC X' since the X is not the prefix key."
;; Set up key-translation-map as indicated by `double-map'. ;; Set up key-translation-map as indicated by `double-map'.
(kill-local-variable 'key-translation-map) (kill-local-variable 'key-translation-map)
(make-local-variable 'key-translation-map) (make-local-variable 'key-translation-map)
(setq key-translation-map (copy-keymap key-translation-map)) (setq key-translation-map (if (keymapp key-translation-map)
(copy-keymap key-translation-map)
(make-sparse-keymap)))
(mapcar (function (lambda (entry) (mapcar (function (lambda (entry)
(define-key key-translation-map (define-key key-translation-map
(vector (nth 0 entry)) (vector (nth 0 entry))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment