# HG changeset patch # User Karl Heuer # Date 764564604 0 # Node ID 7e1e1ccc238cb229a46e83440592b2a814f3553d # Parent cedc6c52a8120b6039e65dc96ee424123da062d5 (apropos-match-keys): Skip duplicate keybindings. diff -r cedc6c52a812 -r 7e1e1ccc238c lisp/apropos.el --- a/lisp/apropos.el Fri Mar 25 03:02:27 1994 +0000 +++ b/lisp/apropos.el Fri Mar 25 03:03:24 1994 +0000 @@ -277,6 +277,9 @@ (not (setq local (lookup-key current-local-map key))) (numberp local) (eq command local)) + ;; check if this binding is already recorded + ;; (this can happen due to inherited keymaps) + (not (member key (nthcdr 3 item))) ;; add this key binding to the item in alist (nconc item (cons key nil)))) ((vectorp (car map)) @@ -305,6 +308,9 @@ (not (setq local (lookup-key current-local-map key))) (numberp local) (eq command local)) + ;; check if this binding is already recorded + ;; (this can happen due to inherited keymaps) + (not (member key (nthcdr 3 item))) ;; add this key binding to the item in alist (nconc item (cons key nil))) (setq i (1+ i))))))