[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#2495: 23.0.91; regression in M-x flush-lines
From: |
Glenn Morris |
Subject: |
bug#2495: 23.0.91; regression in M-x flush-lines |
Date: |
Fri, 27 Feb 2009 16:41:10 -0500 |
User-agent: |
Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) |
Andreas Seltenreich wrote:
> emacs -Q
> M-< ; beginning of *scratch* buffer
> M-x flush-lines RET RET
In 22.3, this used read-from-minibuffer, which returns the empty
string in case of no input.
Now it used read-regexp, which returns nil in case of no input (if no
default is supplied). That doesn't seem right.
Perhaps this:
*** replace.el 9 Jan 2009 05:01:00 -0000 1.282
--- replace.el 27 Feb 2009 21:41:59 -0000
***************
*** 556,562 ****
(format "%s: " prompt))
nil nil nil 'regexp-history defaults t)))
(if (equal input "")
! default-value
(prog1 input
(add-to-history 'regexp-history input)))))
--- 556,562 ----
(format "%s: " prompt))
nil nil nil 'regexp-history defaults t)))
(if (equal input "")
! (or default-value input)
(prog1 input
(add-to-history 'regexp-history input)))))