From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#44611: Prefix arg for xref-goto-xref Date: Sun, 20 Dec 2020 18:10:15 +0200 Message-ID: <37e41473-08ba-7f5b-125e-74140395df88@yandex.ru> References: <87k0up68e4.fsf@mail.linkov.net> <99772eb6-5a4e-7cf6-259d-0e9429e6bf97@yandex.ru> <878sb3n0a9.fsf@mail.linkov.net> <48f942f9-a557-0185-25fe-612e78cd9071@yandex.ru> <875z67gd6z.fsf@mail.linkov.net> <72e9e5e9-651f-401f-2e26-faaac1b7fdb5@yandex.ru> <87v9cxleff.fsf@mail.linkov.net> <834kkhtaxm.fsf@gnu.org> <874kkgswg2.fsf@mail.linkov.net> <83v9cwsct7.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="38951"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 Cc: joaotavora@gmail.com, 44611@debbugs.gnu.org To: Eli Zaretskii , Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Dec 20 17:12:13 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1kr1Jc-000A1w-Ve for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 20 Dec 2020 17:12:13 +0100 Original-Received: from localhost ([::1]:54384 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kr1Jc-0001VZ-2L for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 20 Dec 2020 11:12:12 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41896) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kr1IV-0000ZP-Ae for bug-gnu-emacs@gnu.org; Sun, 20 Dec 2020 11:11:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33849) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kr1IU-0001yi-Eb for bug-gnu-emacs@gnu.org; Sun, 20 Dec 2020 11:11:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kr1IU-0008MY-9A for bug-gnu-emacs@gnu.org; Sun, 20 Dec 2020 11:11:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 20 Dec 2020 16:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44611 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: fixed Original-Received: via spool by 44611-submit@debbugs.gnu.org id=B44611.160848062632107 (code B ref 44611); Sun, 20 Dec 2020 16:11:02 +0000 Original-Received: (at 44611) by debbugs.gnu.org; 20 Dec 2020 16:10:26 +0000 Original-Received: from localhost ([127.0.0.1]:45395 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kr1Hu-0008Lm-FS for submit@debbugs.gnu.org; Sun, 20 Dec 2020 11:10:26 -0500 Original-Received: from mail-wr1-f51.google.com ([209.85.221.51]:38204) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kr1Hs-0008LY-AC for 44611@debbugs.gnu.org; Sun, 20 Dec 2020 11:10:24 -0500 Original-Received: by mail-wr1-f51.google.com with SMTP id r7so8244123wrc.5 for <44611@debbugs.gnu.org>; Sun, 20 Dec 2020 08:10:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=0TvTZ9uhTQ6AgJ+wDiPn8IiHmS023+U1vLA/24bdCjU=; b=C7JhGm4cHrHgBSylh4X3+Ww8OkETYMRWhmhvjoOrFTEKKMSwGg8iIMovtGVCf1X0JA 3ti2DWW9taOKG98XPLVdf84wjrqX7S/KdVFWXIB5GugCsQ8w2OC9G199IsX7v5Ytyp9u r/v4LIb1phA4RVygf/SZZRs9cv+l+/GfpT1ZcPpgLCtpcmZN/zmRis9YhSesWpvVhB1F h3E0Fy2/Kb83TJuqB2rh0Dh5PzwIMROu8zUpv48K2F6rgkw5JGpAqNADH9lPdbk8U1Fg TY97HfY3T0qqulMtdopmi7w/ewaedGH0buu01FmWYIG3xSz48u6pRyMRg8ZXmI0Ib64O yhdQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=0TvTZ9uhTQ6AgJ+wDiPn8IiHmS023+U1vLA/24bdCjU=; b=t6ZvgMCf82zqcGdPGqzU/wlvbkH/+zbAg1z77nDNambON9w26nQ88sg+GKA0pvTeQt SA6j0QY12h7aTtHwUVq/tYu/x8jK4x5LIBzYV6T2GGItgOmURc9q8oGZgXvcLXurl8Wx 8IPJDvLgnJPDbi8/s+DxfqcxZ5MUNC6fohVEIojhqU1lVa2b50A2uC1k5zcu7lgmc1hD /ollC570tAmtuIcRoFVYM5WhbZFe8fjR9IRDLAOGtwzbYtWyCdYq6OhLrRBPFmLXYQgz BeYrpo6MXRn+jWgoYv6TNVyF5R076D5MGJCBgjamBfcXuoYy/RIplOfQo219IjvK9wDw hrhQ== X-Gm-Message-State: AOAM531mBPlly6tqTru+rFJfTD2UMC70nJQHusBy+WoKS0wZNCt1JfO8 xPBvIQdVwwwpuz2PYZ0AkQCmCQ3L7XUqqw== X-Google-Smtp-Source: ABdhPJzRHa6pqF98p7fbZIyGUgpOhbRHP3KqIzTuZphLnTqrXkmlI5hGO2rTCH8Ak1185lgHfwJeeA== X-Received: by 2002:adf:f401:: with SMTP id g1mr14217449wro.258.1608480618248; Sun, 20 Dec 2020 08:10:18 -0800 (PST) Original-Received: from [192.168.0.6] ([46.251.119.176]) by smtp.googlemail.com with ESMTPSA id v189sm20119787wmg.14.2020.12.20.08.10.16 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 20 Dec 2020 08:10:17 -0800 (PST) In-Reply-To: <83v9cwsct7.fsf@gnu.org> Content-Language: en-US X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:196476 Archived-At: Hi Eli, On 20.12.2020 17:43, Eli Zaretskii wrote: >>> This is an incompatible behavior change, no? If so, I'm not sure we >>> can simply make it. >> >> This is what we have the section "Incompatible Editing Changes" in etc/NEWS for. > > The fact that the section exists doesn't mean we can make incompatible > changes whenever we feel like. It does mean we can make such changes when we discover a better way to do things. I think you can agree that we have been, overall, fairly conservative with UI changes in Xref. > This key binding existed since Emacs > 26.1, so changing it would definitely surprise someone. In any case, it was one of the minor, later additions. I would be surprised to find out (if it ever were possible to obtain such data) that > 5% of regular Xref users take advantage of it. And those who do, can discover the change without any terrible consequences (the new binding is pretty benign), look up the docs and adapt. >> And since the new keybinding have no disastrous effect, it would safer >> for the users to adapt to the new keybinding. > > What disastrous effects? AFAICT, TAB buries the XREF buffer, which is > not a disaster. > > More generally, I think it's wrong to try to make XREF buffers behave > like *Grep* buffers. They are different beasts, I think we > established this long ago, when Xref was added to Emacs (I think I > even made a comment regarding the difference, and Dmitry responded to > the effect that this was intended). While I indeed might have said something like that, it was probably in the context of copying some behavior from Grep that didn't make sense for Xref. This one does (IMO), and, in general, reducing gratuitous differences between packages and UIs we provide is a good thing. And if things like that will make Xref more palatable to long-time Compilation/Grep aficionados without conflicting with Xref's goals, I'm all in favor of that. > *XREF* and *Grep* look > differently and behave differently, and it's impossible to make them > be similar enough. If Juri's experience says different, it's a valuable data point. If you recall, we have received a fair number of criticisms for Xref's UI from him over the years. Finally, the binding in question was added when the Xref buffers for "find definition" and "regexp matches in directory" have (without extra user-specific hacks) behaved the same. This has changed with the introduction of the option xref-show-definitions-function, using which we changed the latter's behavior a little. I believe we might change xref-show-definitions-function's default soon enough, perhaps even in Emacs 28. xref--show-defs-minibuffer, which we have come up during a recent discussion in emacs-devel, works quite well in my testing for this particular use case (feedback welcome, BTW). If/when we do, the xref-quit-and-goto-xref binding will lose even more of its importance. Though it should still remain useful on occasion.