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

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

[elpa] externals/hyperbole 6b68100 40/53: Fixed predicate test in kbd-ke


From: Robert Weiner
Subject: [elpa] externals/hyperbole 6b68100 40/53: Fixed predicate test in kbd-key:key-and-arguments.
Date: Wed, 15 Nov 2017 22:47:06 -0500 (EST)

branch: externals/hyperbole
commit 6b68100f3ffbc6d3560a2f9ebbcd2b9aa1884680
Author: Bob Weiner <address@hidden>
Commit: Bob Weiner <address@hidden>

    Fixed predicate test in kbd-key:key-and-arguments.
---
 hib-kbd.el | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/hib-kbd.el b/hib-kbd.el
index 2ddccb4..89cb17d 100644
--- a/hib-kbd.el
+++ b/hib-kbd.el
@@ -57,7 +57,8 @@ Forms such as {\C-b}, {\^b}, and {^b} will not be recognized."
                 (not (eq key-sequence "")))
        (setq key-sequence (kbd-key:normalize key-sequence)
              binding (key-binding key-sequence)))
-      (and (or (and binding (not (integerp binding)))
+      (and (stringp key-sequence)
+          (or (and binding (not (integerp binding)))
               (kbd-key:special-sequence-p key-sequence))
           (ibut:label-set seq-and-pos)
           (hact 'kbd-key key-sequence)))))
@@ -196,10 +197,11 @@ Allows for multiple key sequences strung together."
 
 (defun kbd-key:key-and-arguments (key-sequence)
   "Returns t if normalized KEY-SEQUENCE appears to be a bound key sequence 
possibly with following interactive arguments, else nil."
-  (let ((prefix-binding (and key-sequence (key-binding (substring key-sequence 
0 1)))))
+  (let ((prefix-binding (and (stringp key-sequence) (key-binding (substring 
key-sequence 0 1)))))
        ;; Just ensure that 1st character is bound to something that is
        ;; not a self-insert-command or a number.
-    (and (not (or (integerp prefix-binding)
+    (and prefix-binding
+        (not (or (integerp prefix-binding)
                  (eq prefix-binding 'self-insert-command)))
         t)))
 



reply via email to

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