summaryrefslogtreecommitdiff
path: root/src/keymap.c
diff options
context:
space:
mode:
authorKarl Heuer <kwzh@gnu.org>1994-03-25 03:02:27 +0000
committerKarl Heuer <kwzh@gnu.org>1994-03-25 03:02:27 +0000
commit9fc722dee15cb7544a9920f521911a35e6aa4700 (patch)
treed83e82ba86fe4b0cb22d8f0b0d0dcd217ec6db32 /src/keymap.c
parent26ae6b61cf5289082b0487efa87c565559bb2b35 (diff)
downloademacs-9fc722dee15cb7544a9920f521911a35e6aa4700.tar.gz
emacs-9fc722dee15cb7544a9920f521911a35e6aa4700.tar.bz2
emacs-9fc722dee15cb7544a9920f521911a35e6aa4700.zip
(Fwhere_is_internal): Skip duplicates.
Diffstat (limited to 'src/keymap.c')
-rw-r--r--src/keymap.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/keymap.c b/src/keymap.c
index e5878125c70..1c403dcf234 100644
--- a/src/keymap.c
+++ b/src/keymap.c
@@ -1694,8 +1694,10 @@ indirect definition itself.")
continue;
}
- /* It is a true unshadowed match. Record it. */
- found = Fcons (sequence, found);
+ /* It is a true unshadowed match. Record it, unless it's already
+ been seen (as could happen when inheriting keymaps). */
+ if (NILP (Fmember (sequence, found)))
+ found = Fcons (sequence, found);
/* If firstonly is Qnon_ascii, then we can return the first
binding we find. If firstonly is not Qnon_ascii but not