unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Define-key doc string - binding changes always if it exists
@ 2005-08-10 21:37 Lennart Borgman
  2005-08-11 15:05 ` Kevin Rodgers
  2005-08-12  7:19 ` Stefan Monnier
  0 siblings, 2 replies; 4+ messages in thread
From: Lennart Borgman @ 2005-08-10 21:37 UTC (permalink / raw)


I found the doc string for define-key a bit strange. It kind of suggests 
that if the keymap is not sparse then it is not changed. I suggest the 
following patch:

Index: keymap.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/keymap.c,v
retrieving revision 1.306
diff -u -r1.306 keymap.c
--- keymap.c    7 Aug 2005 12:33:17 -0000    1.306
+++ keymap.c    10 Aug 2005 19:42:37 -0000
@@ -1105,9 +1105,8 @@
     (DEFN should be a valid definition in its own right),
  or a cons (MAP . CHAR), meaning use definition of CHAR in keymap MAP.
 
-If KEYMAP is a sparse keymap with a binding for KEY, the existing
-binding is altered.  If there is no binding for KEY, the new pair
-binding KEY to DEF is added at the front of KEYMAP.  */)
+If KEYMAP is a sparse keymap and there is no binding for KEY, the new
+pair binding KEY to DEF is added at the front of KEYMAP.  */)
      (keymap, key, def)
      Lisp_Object keymap;
      Lisp_Object key;

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2005-08-12  7:19 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-10 21:37 Define-key doc string - binding changes always if it exists Lennart Borgman
2005-08-11 15:05 ` Kevin Rodgers
2005-08-11 15:45   ` Lennart Borgman
2005-08-12  7:19 ` Stefan Monnier

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).