changeset 6524:cedc6c52a812

(Fwhere_is_internal): Skip duplicates.
author Karl Heuer <kwzh@gnu.org>
date Fri, 25 Mar 1994 03:02:27 +0000
parents d9d9ab5951dd
children 7e1e1ccc238c
files src/keymap.c
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/keymap.c	Fri Mar 25 01:34:24 1994 +0000
+++ b/src/keymap.c	Fri Mar 25 03:02:27 1994 +0000
@@ -1694,8 +1694,10 @@
 		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