From: Dmitry Gutov <dmitry@gutov.dev>
To: Siyuan Chen <chansey97@gmail.com>, 71727@debbugs.gnu.org
Subject: bug#71727: Deleting TAGS buffer will cause `etags-regen--update-file` doesn't work
Date: Fri, 28 Jun 2024 04:23:32 +0300 [thread overview]
Message-ID: <d62ebe0d-f847-4c0d-b29d-f916298cc9fe@gutov.dev> (raw)
In-Reply-To: <CAHWTsY=Ef3+zoQZyHczBmcTZeLmti7ciaH6NPjSDZJwUSt6q4A@mail.gmail.com>
Hi!
Thanks for the report.
On 23/06/2024 02:55, Siyuan Chen wrote:
> 5. M-x kill-buffer TAGS
>
> 6. Add `#define APPLICATION_WINDOW_HEIGHT 320` to test.c and M-x save-buffer
>
> 7. Move the cursor to APPLICATION_WINDOW_HEIGHT and M-x
> xref-find-definitions.
What happens here, is etags-regen--update-file (added to
after-save-hook) fails the check
(get-file-buffer etags-regen--tags-file)
and so the buffer and the file are not updated.
Note that if after step 7 you make an edit to the same file and then try
navigating again it will work because at step 7 the tags file is visited
again. So this doesn't seem an urgent problem, but it would be nice to
fix nevertheless.
I think we couldn't re-visit the tags file inside after-save-hook (it
might not be fast enough, for one thing), but the second alternative
mentioned inside the TODO at the top of etags-regen--update-file should
be fix this as well.
Is there are particular reason you killed the TAGS buffer? Perhaps a
quicker fix would be to visit the tags file in a hidden buffer, rather
than use the name that's so easy to find and kill or do something else
by accident.
next prev parent reply other threads:[~2024-06-28 1:23 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-22 23:55 bug#71727: Deleting TAGS buffer will cause `etags-regen--update-file` doesn't work Siyuan Chen
2024-06-27 8:49 ` Eli Zaretskii
2024-06-28 1:23 ` Dmitry Gutov [this message]
2024-06-29 11:49 ` Siyuan Chen
2024-07-09 2:50 ` Dmitry Gutov
2024-07-11 0:50 ` 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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d62ebe0d-f847-4c0d-b29d-f916298cc9fe@gutov.dev \
--to=dmitry@gutov.dev \
--cc=71727@debbugs.gnu.org \
--cc=chansey97@gmail.com \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).