From 89ee2bf6202076a005a699e4de57afcd55f26c04 Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Wed, 25 Aug 1999 21:12:15 +0000 Subject: [PATCH] (kill-word): Undo previous change. --- lisp/simple.el | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/lisp/simple.el b/lisp/simple.el index a407994945e..456911c6c9a 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -794,7 +794,9 @@ An uppercase letter in REGEXP makes the search case-sensitive." (let ((print-level nil)) (prin1-to-string elt)) elt)) - (goto-char (minibuffer-prompt-end))))) + (if (boundp 'minibuffer-prompt-in-buffer) + (goto-char (minibuffer-prompt-width)) + (goto-char (point-min)))))) (defun previous-history-element (n) "Inserts the previous element of the minibuffer history into the minibuffer." @@ -2847,12 +2849,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") - (let ((start (point)) - (end (progn (forward-word arg) (point))) - (prompt-end (minibuffer-prompt-end))) - (when (< end prompt-end) - (goto-char (setq end prompt-end))) - (kill-region start end))) + (kill-region (point) (progn (forward-word arg) (point)))) (defun backward-kill-word (arg) "Kill characters backward until encountering the end of a word. -- 2.39.5