Don't mutate string literal
* lisp/obsolete/terminal.el (terminal-escape-map): Rewrite loop in a simpler and more robust way.
This commit is contained in:
parent
f804248b4f
commit
c69b4768d6
1 changed files with 3 additions and 4 deletions
|
@ -112,10 +112,9 @@ performance."
|
|||
nil
|
||||
(let ((map (make-sparse-keymap)))
|
||||
(define-key map [t] #'undefined)
|
||||
(let ((s "0"))
|
||||
(while (<= (aref s 0) ?9)
|
||||
(define-key map s #'digit-argument)
|
||||
(aset s 0 (1+ (aref s 0)))))
|
||||
(dotimes (i 10)
|
||||
(let ((s (make-string 1 (+ ?0 i))))
|
||||
(define-key map s #'digit-argument)))
|
||||
(define-key map "b" #'switch-to-buffer)
|
||||
(define-key map "o" #'other-window)
|
||||
(define-key map "e" #'te-set-escape-char)
|
||||
|
|
Loading…
Add table
Reference in a new issue