From: Stephen Leake <stephen_leake@stephe-leake.org>
To: emacs-devel <emacs-devel@gnu.org>
Subject: xref call project-current in correct buffer
Date: Tue, 15 Nov 2022 10:49:53 -0800 [thread overview]
Message-ID: <8635ak9hny.fsf@stephe-leake.org> (raw)
I ran into a situation where xref failed because
xref-show-definitions-buffer-at-bottom calls project-current in the
*xref* buffer, not the original source buffer, and the project in that
buffer is different from the one in the *xref* buffer.
The attached patch fixes it, but there are other possible ways to do it;
pass the project to xref--analyze, or set a local variable containing
the project.
In addition, refresh-buffer in the *xref* buffer will have the same
problem, so setting the original project in a local variable might be
the best way.
--
-- Stephe
next reply other threads:[~2022-11-15 18:49 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-15 18:49 Stephen Leake [this message]
2022-11-15 20:10 ` xref call project-current in correct buffer Eli Zaretskii
2022-11-15 21:37 ` Stephen Leake
2022-11-15 21:48 ` Dmitry Gutov
2022-11-15 21:55 ` Dmitry Gutov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8635ak9hny.fsf@stephe-leake.org \
--to=stephen_leake@stephe-leake.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.