emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/abbrev.el,v


From: Stefan Monnier
Subject: [Emacs-diffs] Changes to emacs/lisp/abbrev.el,v
Date: Thu, 05 Jun 2008 05:06:59 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Stefan Monnier <monnier>        08/06/05 05:06:58

Index: abbrev.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/abbrev.el,v
retrieving revision 1.75
retrieving revision 1.76
diff -u -b -r1.75 -r1.76
--- abbrev.el   8 May 2008 03:35:38 -0000       1.75
+++ abbrev.el   5 Jun 2008 05:06:58 -0000       1.76
@@ -824,10 +824,11 @@
         ;; to do the expansion.
         (let ((val (symbol-value last-abbrev)))
           (unless (stringp val)
-            (error "value of abbrev-symbol must be a string"))
-          (delete-region (point) (+ (point) (length val)))
+            (error "Value of abbrev-symbol must be a string"))
           ;; Don't inherit properties here; just copy from old contents.
           (insert last-abbrev-text)
+          ;; Delete after inserting, to better preserve markers.
+          (delete-region (point) (+ (point) (length val)))
           (setq last-abbrev-text nil))))))
 
 (defun abbrev--write (sym)




reply via email to

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