unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: David Fussner <dfussner@googlemail.com>, Dmitry Gutov <dgutov@yandex.ru>
Cc: 52734@debbugs.gnu.org
Subject: bug#52734: 28.0.90; [PATCH] xref-backend-definitions in etags.el duplicates list
Date: Thu, 23 Dec 2021 11:12:33 +0200	[thread overview]
Message-ID: <831r23wupq.fsf@gnu.org> (raw)
In-Reply-To: <CADF+Rtj96R5c5rn4N8TM_Mvf9ctgqQQF5N=4uEwjfc62yzrxpg@mail.gmail.com> (bug-gnu-emacs@gnu.org)

> Date: Wed, 22 Dec 2021 15:01:54 +0000
> From:  David Fussner via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
> 
> When `etags-xref-prefer-current-file' is t and only the current file
> contains (multiple) definitions of the same function, the list returns
> each tag twice.  To reproduce:
> 
> cd src/
> ../lib-src/etags term.c
> ./emacs -Q term.c
> C-s tty_free_frame_resources RTN
> M-. RTN
> 
> src/term.c
> 3786: tty_free_frame_resources
> 3798: tty_free_frame_resources
> 
> (setq etags-xref-prefer-current-file t)
> M-.
> 
> src/term.c
> 3786: tty_free_frame_resources
> 3798: tty_free_frame_resources
> 3786: tty_free_frame_resources
> 3798: tty_free_frame_resources
> 
> The variable is new in 28.1, so I thought the bug might want fixing on
> this branch.  In my testing, cl-delete appears not to delete ITEMs from
> SEQ if such deletion would leave SEQ empty.  I can't find this behavior
> documented anywhere, but I may be looking in the wrong places.
> 
> Patch attached, which just tests for equality of the two lists of
> definitions, and only returns one of them in that case.

Dmitry, any comments?  The patch LGTM, FWIW.





  reply	other threads:[~2021-12-23  9:12 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-22 15:01 bug#52734: 28.0.90; [PATCH] xref-backend-definitions in etags.el duplicates list David Fussner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-12-23  9:12 ` Eli Zaretskii [this message]
2021-12-24  0:27   ` Dmitry Gutov
2021-12-24  7:08     ` Eli Zaretskii
2021-12-24 13:09       ` David Fussner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-12-24 13:20         ` Eli Zaretskii
2021-12-24 13:27           ` Dmitry Gutov
2021-12-24  0:25 ` 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=831r23wupq.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=52734@debbugs.gnu.org \
    --cc=dfussner@googlemail.com \
    --cc=dgutov@yandex.ru \
    /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).