+2010-12-20 Juri Linkov <juri@jurta.org>
+
+ * isearch.el (isearch-lazy-highlight-error): New variable.
+ (isearch-lazy-highlight-new-loop): Compare `isearch-error' and
+ `isearch-lazy-highlight-error'. Set `isearch-lazy-highlight-error'
+ to the current value of `isearch-error' (Bug#7468).
+
2010-12-17 Chong Yidong <cyd@stupidchicken.com>
* help-fns.el (describe-variable): Don't emit trailing whitespace
(defvar isearch-lazy-highlight-regexp nil)
(defvar isearch-lazy-highlight-space-regexp nil)
(defvar isearch-lazy-highlight-forward nil)
+(defvar isearch-lazy-highlight-error nil)
(defun lazy-highlight-cleanup (&optional force)
"Stop lazy highlighting and remove extra highlighting from current buffer.
(not (= (window-end) ; Window may have been split/joined.
isearch-lazy-highlight-window-end))
(not (eq isearch-forward
- isearch-lazy-highlight-forward))))
+ isearch-lazy-highlight-forward))
+ ;; In case we are recovering from an error.
+ (not (equal isearch-error
+ isearch-lazy-highlight-error))))
;; something important did indeed change
(lazy-highlight-cleanup t) ;kill old loop & remove overlays
+ (setq isearch-lazy-highlight-error isearch-error)
(when (not isearch-error)
(setq isearch-lazy-highlight-start-limit beg
isearch-lazy-highlight-end-limit end)