diff options
author | Richard M. Stallman <rms@gnu.org> | 1995-12-01 20:18:18 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1995-12-01 20:18:18 +0000 |
commit | fa4ca9f707c5166841be1a631ba89394b142c198 (patch) | |
tree | 8ea90b5500791d472b34e589155b06ce667cee30 /lisp/isearch.el | |
parent | 986b7d6a5a597bf4c3320089a472aaad021094b8 (diff) | |
download | emacs-fa4ca9f707c5166841be1a631ba89394b142c198.tar.gz |
(isearch-edit-string): Consider the case when
iserch-string is empty and so are the search rings.
Diffstat (limited to 'lisp/isearch.el')
-rw-r--r-- | lisp/isearch.el | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lisp/isearch.el b/lisp/isearch.el index cd035b08b3e..bbcc08bf00b 100644 --- a/lisp/isearch.el +++ b/lisp/isearch.el @@ -552,7 +552,7 @@ is treated as a regexp. See \\[isearch-forward] for more info." (or (and transient-mark-mode mark-active) (progn (push-mark isearch-opoint t) - (or executing-macro (> (minibuffer-depth) 0) + (or executing-kbd-macro (> (minibuffer-depth) 0) (message "Mark saved where search started")))))) (setq isearch-mode nil) @@ -726,8 +726,10 @@ If first char entered is \\[isearch-yank-word], then do word search instead." ;; Empty isearch-string means use default. (if (= 0 (length isearch-string)) - (setq isearch-string (car (if isearch-regexp regexp-search-ring - search-ring))) + (setq isearch-string (or (car (if isearch-regexp + regexp-search-ring + search-ring)) + "")) ;; This used to set the last search string, ;; but I think it is not right to do that here. ;; Only the string actually used should be saved. |