Commit 01b8e020 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(kill-word): Don't change point before calling kill-region.

(delete-indentation): Don't go beyond eob, comparing with fill-prefix.
parent d840a865
......@@ -69,6 +69,7 @@ With argument, join this line to following line."
;; If the second line started with the fill prefix,
;; delete the prefix.
(if (and fill-prefix
(<= (+ (point) (length fill-prefix)) (point-max))
(string= fill-prefix
(buffer-substring (point)
(+ (point) (length fill-prefix)))))
......@@ -1570,7 +1571,7 @@ In programs, it is faster to call `forward-word' with negative arg."
"Kill characters forward until encountering the end of a word.
With argument, do this that many times."
(interactive "p")
(kill-region (point) (progn (forward-word arg) (point))))
(kill-region (point) (save-excursion (forward-word arg) (point))))
(defun backward-kill-word (arg)
"Kill characters backward until encountering the end of a word.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment