From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: master b02c9bc: Improve documentation of new Xref options Date: Wed, 08 Sep 2021 09:18:00 +0300 Message-ID: <83lf47oajr.fsf@gnu.org> References: <20210907130400.31609.90502@vcs0.savannah.gnu.org> <20210907130401.D074320A10@vcs0.savannah.gnu.org> <83a6kopeye.fsf@gnu.org> <8335qgpd64.fsf@gnu.org> <9aef615d-039a-0c9f-fda7-f3fb11db9d47@yandex.ru> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="5204"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Dmitry Gutov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Sep 08 08:18:36 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mNquq-0001Ds-Rj for ged-emacs-devel@m.gmane-mx.org; Wed, 08 Sep 2021 08:18:36 +0200 Original-Received: from localhost ([::1]:47184 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mNqup-00044c-EK for ged-emacs-devel@m.gmane-mx.org; Wed, 08 Sep 2021 02:18:35 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50938) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mNqu6-0003PR-PC for emacs-devel@gnu.org; Wed, 08 Sep 2021 02:17:51 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:52446) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mNqu6-0006b7-7R; Wed, 08 Sep 2021 02:17:50 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:2788 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mNqu5-0005O0-Qj; Wed, 08 Sep 2021 02:17:50 -0400 In-Reply-To: <9aef615d-039a-0c9f-fda7-f3fb11db9d47@yandex.ru> (message from Dmitry Gutov on Wed, 8 Sep 2021 03:24:12 +0300) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:274314 Archived-At: > Cc: emacs-devel@gnu.org > From: Dmitry Gutov > Date: Wed, 8 Sep 2021 03:24:12 +0300 > > On 07.09.2021 19:23, Eli Zaretskii wrote: > >>> No, it's about the features listed after the shown hunk. I just made > >>> its language less extreme, because xref-find-apropos does exist. > >> tags-apropos-additional-actions, then? That seems easier to support. > > Yes, pretty much. > > Here's a quick implementation. Thanks. > But the feature doesn't seem to be particularly popular/polished: the > example value for Elisp, for instance, sets up search across all symbols > (obarray), but subsequent navigation only works for commands, and only > ones documented in the manual. I don't think we should be too bothered about that: once we have replacements for all of those etags features, we could declare the originals obsolete and point to replacements, something we cannot do when the replacements are missing. So I think we should install this. > (cl-defmethod xref-backend-apropos ((_backend (eql 'etags)) pattern) > - (etags--xref-find-definitions (xref-apropos-regexp pattern) t)) > + (let ((regexp (xref-apropos-regexp pattern))) > + (nconc > + (etags--xref-find-definitions regexp t) > + (etags--xref-apropos-additional regexp)))) I'm not sure I understand why is this specific to the etags backend. The spec seems to be more general, and xref-find-apropos is not specific to etags, right? We'd also need a defcustom, similar to tags-apropos-additional-actions.