HCoop
/
bpt
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b64d744
)
(Fset_keymap_parent): Return early if KEYMAP already has the proper parent.
author
Richard M. Stallman
<rms@gnu.org>
Wed, 12 Jun 1996 21:47:59 +0000
(21:47 +0000)
committer
Richard M. Stallman
<rms@gnu.org>
Wed, 12 Jun 1996 21:47:59 +0000
(21:47 +0000)
src/keymap.c
patch
|
blob
|
blame
|
history
diff --git
a/src/keymap.c
b/src/keymap.c
index
a0c28bb
..
88f89cd
100644
(file)
--- a/
src/keymap.c
+++ b/
src/keymap.c
@@
-307,6
+307,11
@@
PARENT should be nil or another keymap.")
If we came to the end, add the parent in PREV. */
if (! CONSP (list) || EQ (Qkeymap, XCONS (list)->car))
{
+ /* If we already have the right parent, return now
+ so that we avoid the loops below. */
+ if (EQ (XCONS (prev)->cdr, parent))
+ return parent;
+
XCONS (prev)->cdr = parent;
break;
}