emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/ergoemacs-mode 131b3fb 62/87: Fix command-loop errors


From: Stefan Monnier
Subject: [elpa] externals/ergoemacs-mode 131b3fb 62/87: Fix command-loop errors
Date: Wed, 14 Apr 2021 18:47:08 -0400 (EDT)

branch: externals/ergoemacs-mode
commit 131b3fb409c79b66d6715608a71be884a0bde82f
Author: Walter Landry <wlandry@caltech.edu>
Commit: Walter Landry <wlandry@caltech.edu>

    Fix command-loop errors
    
    The problem was that mapkeymap was looking for a prefix in a keymap
    and assuming that the result was a list.  This will fail when invoking
    'term', because it has a keymap with a lot of elements specified as
    
      #^^[3 0 term-send-raw-meta term-send-raw-meta ...
    
    We now check explicitly for whether the result is a list.
---
 ergoemacs-mapkeymap.el | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/ergoemacs-mapkeymap.el b/ergoemacs-mapkeymap.el
index cb08017..199329e 100644
--- a/ergoemacs-mapkeymap.el
+++ b/ergoemacs-mapkeymap.el
@@ -194,7 +194,9 @@ them to be masked when mapping over the keymap."
              (cond
               ((consp event)
                (ergoemacs-map-set-char-table-range
-                (or (and prefix (lookup-key flat-keymap prefix))
+                (or (and prefix
+                         (let ((prefix-lookup (lookup-key flat-keymap prefix)))
+                           (if (listp prefix-lookup) prefix-lookup)))
                     flat-keymap) event item))
               (t
                (define-key flat-keymap key item)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]