mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-01-30 04:10:54 -08:00
(occur-mode-goto-occurrence): Give meaningful error
message if there's nowhere useful to go.
This commit is contained in:
parent
314ed6a5aa
commit
43549f18f5
1 changed files with 2 additions and 0 deletions
|
|
@ -250,6 +250,8 @@ in the buffer that the occurrences were found in.
|
|||
(+ 2 (* 2 occur-nlines)))
|
||||
(t 1)))))
|
||||
(pos (nth occur-number occur-pos-list)))
|
||||
(or pos
|
||||
(error "No occurrence on this line"))
|
||||
(pop-to-buffer occur-buffer)
|
||||
(goto-char (marker-position pos))))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue