From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#35737: xref--original-command Date: Sat, 25 May 2019 01:48:28 +0300 Message-ID: References: <87ftpgu59l.fsf@mail.linkov.net> <56943df5-f366-a8af-cb95-a40c244da837@yandex.ru> <87tvdvpgzj.fsf@mail.linkov.net> <87woiqkwok.fsf@mail.linkov.net> <87r28nenzk.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="117300"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 Cc: 35737@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat May 25 00:49:14 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hUIzy-000UPT-18 for geb-bug-gnu-emacs@m.gmane.org; Sat, 25 May 2019 00:49:14 +0200 Original-Received: from localhost ([127.0.0.1]:32815 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hUIzw-0001u2-R2 for geb-bug-gnu-emacs@m.gmane.org; Fri, 24 May 2019 18:49:12 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:49451) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hUIzn-0001tv-DX for bug-gnu-emacs@gnu.org; Fri, 24 May 2019 18:49:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hUIzm-0007eN-EE for bug-gnu-emacs@gnu.org; Fri, 24 May 2019 18:49:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:34024) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hUIzm-0007eB-Aj for bug-gnu-emacs@gnu.org; Fri, 24 May 2019 18:49:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hUIzm-0007Aq-84 for bug-gnu-emacs@gnu.org; Fri, 24 May 2019 18:49:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 24 May 2019 22:49:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35737 X-GNU-PR-Package: emacs Original-Received: via spool by 35737-submit@debbugs.gnu.org id=B35737.155873812427548 (code B ref 35737); Fri, 24 May 2019 22:49:02 +0000 Original-Received: (at 35737) by debbugs.gnu.org; 24 May 2019 22:48:44 +0000 Original-Received: from localhost ([127.0.0.1]:47566 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hUIzT-0007AF-TS for submit@debbugs.gnu.org; Fri, 24 May 2019 18:48:44 -0400 Original-Received: from mail-wm1-f53.google.com ([209.85.128.53]:38117) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hUIzR-00079x-RU for 35737@debbugs.gnu.org; Fri, 24 May 2019 18:48:42 -0400 Original-Received: by mail-wm1-f53.google.com with SMTP id t5so10605992wmh.3 for <35737@debbugs.gnu.org>; Fri, 24 May 2019 15:48:41 -0700 (PDT) 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=gCR6khwK8eDTbOmPfRcy3wcv5Tu17H2yPKJpfuGjloA=; b=rrfHAYF2FNnt3qvk2HyvC5IO6CwDCYhJ6ZG42noHSlLQMyl+E0Yz4ZKdVDfWy1Z1Gj K5yqy5oLGK2Ul5LdMhjo+8m5XyBJrZV2lGtmdajc2pI0LsbqRZrTTC5+4WYjfn1f+gbf pvp5jz0pEKHTkppkpIDykWdSY4Lc9Z/a6wEQneqOAgmY5NUa9OyHycV2ReCU6Zyttjwv 4S20QFBK3Q7VFs3fb+VaqEKX4JXqdwmCWhgxliPAu2mTVbCA9GYqCDvgKqaqvxwHK5SV V5LxCi/LB2n3kmvbeMln9ndHEPRLGqU3uZnMgh7ZZ58DoB+v3pj7EbDbbHVVpJgZdKTA IFkw== 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=gCR6khwK8eDTbOmPfRcy3wcv5Tu17H2yPKJpfuGjloA=; b=ilPloGzFdNs0IC/XFWC2KBcEOJcLbENRItl4yfKDayUpkHyt//IYv4biqncXW0cHys XGIBTD1X03XEwmNg/h1Qizw47tet9UdnW/hyrdIsedeX32zX3A/1T+14qq7FH7wjZ0Er Ui2IUmP7l8Eg4piCsGMUHcFq21IjsXOv1bIxzVHoZLjnlG4w2gfCdfh1MONYyFec5iTM yg6y7Ubc5Qi5+5srEhX4qGkdGrGldklHvdJR/2EyPL4/Wn0Vos3Mh6QKfCpEvCZwdfoT /PvQo7E279YAkKdoctPuXT7qeOfUIhnTqEUXWZ6rCtGMJbYihoj9jQakBn+MU5NtvpLs sfsA== X-Gm-Message-State: APjAAAVC1PJBdm4VaZJTnfBuWAT6QJDHW2FNOKjabp/U/ggf8EXAXHL5 6gp4oghXDPqzFXnTuqM8rfevQ7Ki X-Google-Smtp-Source: APXvYqz6BxYlK6PTmiJcPCheIFWUdmGcE32hwHFKRsTHEG+SNDH1GBfbUCmzacuMDu9fVlgeoZU01Q== X-Received: by 2002:a7b:ce8c:: with SMTP id q12mr1408134wmj.34.1558738115526; Fri, 24 May 2019 15:48:35 -0700 (PDT) Original-Received: from [192.168.1.3] ([185.105.174.23]) by smtp.googlemail.com with ESMTPSA id s11sm6855772wrb.71.2019.05.24.15.48.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 24 May 2019 15:48:34 -0700 (PDT) In-Reply-To: <87r28nenzk.fsf@mail.linkov.net> Content-Language: en-US X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:159739 Archived-At: On 24.05.2019 21:40, Juri Linkov wrote: > Thanks, I tried xref revert and it works fine. > Also I agree with Eli regarding the command name, > documentation and NEWS. Should be good now. > But I don't want to write a new function. I just need to check > if the xref buffer was created by a particular command. I think you need to make a choice here. Do you want to customize your personal Emacs, or do you want to improve the default behavior? If it's the former, I think the advice you posted will work as well as any other solution. I was kind of expecting the latter. > If despite a chain of indirections, xref still can't distinguish > different commands that created the xref buffer, I'd rather close > this feature request and use 'advice-add' in customization. Do we really need to be able to distinguish between xref-find-references and project-find-regexp as well? TBH, xref--original-command is easy to add, but then we'll have an internal variable that isn't used anywhere. Somebody will just delete it someday.