aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/abbrev.el8
1 files changed, 4 insertions, 4 deletions
diff --git a/lisp/abbrev.el b/lisp/abbrev.el
index c6133be034f..83d4a86a2d7 100644
--- a/lisp/abbrev.el
+++ b/lisp/abbrev.el
@@ -225,7 +225,7 @@ Don't use this function in a Lisp program; use `define-abbrev' instead."
225 225
226(defun add-abbrev (table type arg) 226(defun add-abbrev (table type arg)
227 (let ((exp (and (>= arg 0) 227 (let ((exp (and (>= arg 0)
228 (buffer-substring 228 (buffer-substring-no-properties
229 (point) 229 (point)
230 (if (= arg 0) (mark) 230 (if (= arg 0) (mark)
231 (save-excursion (forward-word (- arg)) (point)))))) 231 (save-excursion (forward-word (- arg)) (point))))))
@@ -266,8 +266,8 @@ Expands the abbreviation after defining it."
266 (let (name nameloc exp) 266 (let (name nameloc exp)
267 (save-excursion 267 (save-excursion
268 (forward-word (- arg)) 268 (forward-word (- arg))
269 (setq name (buffer-substring (point) (progn (forward-word 1) 269 (setq name (buffer-substring-no-properties
270 (setq nameloc (point)))))) 270 (point) (progn (forward-word 1) (setq nameloc (point))))))
271 (set-text-properties 0 (length name) nil name) 271 (set-text-properties 0 (length name) nil name)
272 (setq exp (read-string (format "%s expansion for \"%s\": " 272 (setq exp (read-string (format "%s expansion for \"%s\": "
273 type name) nil nil nil t)) 273 type name) nil nil nil t))
@@ -306,7 +306,7 @@ If called from a Lisp program, arguments are START END &optional NOQUERY."
306 (<= (setq pnt (point)) (- (point-max) lim)))) 306 (<= (setq pnt (point)) (- (point-max) lim))))
307 (if (abbrev-expansion 307 (if (abbrev-expansion
308 (setq string 308 (setq string
309 (buffer-substring 309 (buffer-substring-no-properties
310 (save-excursion (forward-word -1) (point)) 310 (save-excursion (forward-word -1) (point))
311 pnt))) 311 pnt)))
312 (if (or noquery (y-or-n-p (format "Expand `%s'? " string))) 312 (if (or noquery (y-or-n-p (format "Expand `%s'? " string)))