emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/src/insdel.c,v [EMACS_22_BASE]


From: Richard M. Stallman
Subject: [Emacs-diffs] Changes to emacs/src/insdel.c,v [EMACS_22_BASE]
Date: Sun, 29 Apr 2007 21:56:24 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Branch:         EMACS_22_BASE
Changes by:     Richard M. Stallman <rms>       07/04/29 21:56:23

Index: insdel.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/insdel.c,v
retrieving revision 1.190
retrieving revision 1.190.2.1
diff -u -b -r1.190 -r1.190.2.1
--- insdel.c    28 Feb 2007 22:21:25 -0000      1.190
+++ insdel.c    29 Apr 2007 21:56:23 -0000      1.190.2.1
@@ -1603,8 +1603,12 @@
 
   if (! EQ (current_buffer->undo_list, Qt))
     {
+      /* Record the insertion first, so that when we undo,
+        the deletion will be undone first.  Thus, undo
+        will insert before deleting, and thus will keep
+        the markers before and after this text separate.  */
+      record_insert (from + SCHARS (deletion), inschars);
       record_delete (from, deletion);
-      record_insert (from, inschars);
     }
 
   GAP_SIZE -= outgoing_insbytes;




reply via email to

[Prev in Thread] Current Thread [Next in Thread]