* Verifying tags in the wrong file
@ 2022-11-09 11:46 Juanma Barranquero
2022-11-09 20:57 ` Bob Rogers
0 siblings, 1 reply; 3+ messages in thread
From: Juanma Barranquero @ 2022-11-09 11:46 UTC (permalink / raw)
To: Emacs developers
[-- Attachment #1: Type: text/plain, Size: 773 bytes --]
M-x load-library <RET> etags <RET>
M-: (tags-verify-table "any-file-not-tags") <RET>
It returns nil and leaves behind a buffer visiting the file, in Tags Table
mode. Not nice, but more or less as expected. Not a bug.
However, if you verify a (no tags) file already being visited in a buffer,
it returns nil and *leaves* the buffer in Tags Table mode!
Well, you'll say, "don't do that". Ok, except that you can do it by
accident, for example if you're using bs-show and happen to type "t" in the
wrong line.
Which, arguably, could be fixed in bs (though I think it's a bug in
etags.el, not bs.el), except that I don't think there's a
tags-table-buffer-p or equivalent to check that the buffer contains a Tags
Table. The way to test it seems to be `tags-verify-table'...
[-- Attachment #2: Type: text/html, Size: 1118 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Verifying tags in the wrong file
2022-11-09 11:46 Verifying tags in the wrong file Juanma Barranquero
@ 2022-11-09 20:57 ` Bob Rogers
2022-11-10 0:28 ` Juanma Barranquero
0 siblings, 1 reply; 3+ messages in thread
From: Bob Rogers @ 2022-11-09 20:57 UTC (permalink / raw)
To: Juanma Barranquero; +Cc: Emacs developers
From: Juanma Barranquero <lekktu@gmail.com>
Date: Wed, 9 Nov 2022 12:46:58 +0100
M-x load-library <RET> etags <RET>
M-: (tags-verify-table "any-file-not-tags") <RET>
It returns nil and leaves behind a buffer visiting the file, in Tags Table
mode. Not nice, but more or less as expected. Not a bug.
However, if you verify a (no tags) file already being visited in a buffer,
it returns nil and *leaves* the buffer in Tags Table mode!
Well, you'll say, "don't do that". Ok, except that you can do it by
accident, for example if you're using bs-show and happen to type "t" in the
wrong line.
Which, arguably, could be fixed in bs (though I think it's a bug in
etags.el, not bs.el), except that I don't think there's a
tags-table-buffer-p or equivalent to check that the buffer contains a Tags
Table. The way to test it seems to be `tags-verify-table'...
I had a similar issue recently (see bug#54133 [1]) though coming from
buffer-menu-mode. I would recommend filing a bug report, though the
upshot was that in some situations putting the buffer into
tags-table-mode is TRT, but making it harder to do by accident is also a
good thing.
-- Bob Rogers
http://www.rgrjr.com/
[1] https://debbugs.gnu.org/cgi/bugreport.cgi?bug=54133
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Verifying tags in the wrong file
2022-11-09 20:57 ` Bob Rogers
@ 2022-11-10 0:28 ` Juanma Barranquero
0 siblings, 0 replies; 3+ messages in thread
From: Juanma Barranquero @ 2022-11-10 0:28 UTC (permalink / raw)
To: Bob Rogers; +Cc: Emacs developers
[-- Attachment #1: Type: text/plain, Size: 154 bytes --]
Indeed, it's the same bug, and the code in bs.el is almost identical to the
one in buff-menu.el. So Eli's patch works. I'll install it for bs.el
Thanks.
[-- Attachment #2: Type: text/html, Size: 334 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-11-10 0:28 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-09 11:46 Verifying tags in the wrong file Juanma Barranquero
2022-11-09 20:57 ` Bob Rogers
2022-11-10 0:28 ` Juanma Barranquero
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).