GNU bug report logs - #28995
xref next-error breaks with with-selected-window in next-error-hook

Previous Next

Package: emacs;

Reported by: Jonathan Kotta <jpkotta <at> gmail.com>

Date: Wed, 25 Oct 2017 16:19:02 UTC

Severity: normal

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 28995 <at> debbugs.gnu.org (full text, mbox):

From: Dmitry Gutov <dgutov <at> yandex.ru>
To: Jonathan Kotta <jpkotta <at> gmail.com>, 28995 <at> debbugs.gnu.org
Subject: Re: bug#28995: xref next-error breaks with with-selected-window in
 next-error-hook
Date: Wed, 25 Oct 2017 23:17:40 +0300
On 10/25/17 7:17 PM, Jonathan Kotta wrote:
> Evaluate:
> 
> (defun jpk/next-error-hook ()
>    (let ((win (get-buffer-window next-error-last-buffer)))
>      (when (window-live-p win)
>        (with-selected-window win ;; breaks with xref
>          (message "window: %s" win)))))
> (add-hook 'next-error-hook #'jpk/next-error-hook)
> 
> Run xref-find-references on e.g. add-hook
> Run next-error or previous-error at least twice.
> 
> Repeating next-error doesn't find the next match after the 2nd 
> invocation. Running previous-error behaves similarly.  I can use a mouse 
> to click on an any match, but next/previous-error will still only move 
> between the clicked match and the next.  I can only cycle between two 
> matches.

Can you reproduce this starting with 'emacs -Q'? I can't.




This bug report was last modified 7 years and 97 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.