Let-bind isearch-lazy-count and lazy-highlight-buffer to nil to avoid
revisiting all matches in the whole buffer after every replacement.
(isearch-case-fold-search case-fold)
(isearch-forward (not backward))
(isearch-other-end match-beg)
- (isearch-error nil))
+ (isearch-error nil)
+ (isearch-lazy-count nil)
+ (lazy-highlight-buffer nil))
(isearch-lazy-highlight-new-loop range-beg range-end))))
(defun replace-dehighlight ()