aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/replace.el
diff options
context:
space:
mode:
authorEli Zaretskii2018-10-09 17:55:15 +0300
committerEli Zaretskii2018-10-09 17:55:15 +0300
commit262f5c809913a232a931131d040964cbdf4ac6f9 (patch)
tree04ecc00b995f16177d4e6cc8e6c869a726095291 /lisp/replace.el
parentcbb674287878877abe38065d0cc5fa28b7fc577d (diff)
downloademacs-262f5c809913a232a931131d040964cbdf4ac6f9.tar.gz
emacs-262f5c809913a232a931131d040964cbdf4ac6f9.zip
Revert part of last commit
* lisp/replace.el (occur-revert-function): Revert last change, as it's no longer needed. (Bug#32987)
Diffstat (limited to 'lisp/replace.el')
-rw-r--r--lisp/replace.el14
1 files changed, 1 insertions, 13 deletions
diff --git a/lisp/replace.el b/lisp/replace.el
index 7d313842c04..a134e4e3e58 100644
--- a/lisp/replace.el
+++ b/lisp/replace.el
@@ -1207,19 +1207,7 @@ To return to ordinary Occur mode, use \\[occur-cease-edit]."
1207 1207
1208(defun occur-revert-function (_ignore1 _ignore2) 1208(defun occur-revert-function (_ignore1 _ignore2)
1209 "Handle `revert-buffer' for Occur mode buffers." 1209 "Handle `revert-buffer' for Occur mode buffers."
1210 (if (cdr (nth 2 occur-revert-arguments)) ; multi-occur 1210 (apply #'occur-1 (append occur-revert-arguments (list (buffer-name)))))
1211 (apply 'occur-1 (append occur-revert-arguments (list (buffer-name))))
1212 (pcase-let ((`(,region-start ,region-end ,orig-line ,buffer)
1213 (occur--parse-occur-buffer))
1214 (regexp (car occur-revert-arguments)))
1215 (if (not (or region-start region-end))
1216 (apply 'occur-1 (append occur-revert-arguments (list (buffer-name))))
1217 (with-current-buffer buffer
1218 (when (wholenump orig-line)
1219 (goto-char (point-min))
1220 (forward-line (1- orig-line)))
1221 (save-excursion
1222 (occur regexp nil (list (cons region-start region-end)))))))))
1223 1211
1224(defun occur-mode-find-occurrence () 1212(defun occur-mode-find-occurrence ()
1225 (let ((pos (get-text-property (point) 'occur-target))) 1213 (let ((pos (get-text-property (point) 'occur-target)))