From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: William Xu Newsgroups: gmane.emacs.devel Subject: Re: Xref completion Date: Wed, 18 Nov 2020 19:53:41 +0100 Organization: the Church of Emacs Message-ID: References: <873617ets1.fsf@ambrevar.xyz> <878sazzsw5.fsf@mail.linkov.net> <7593e751-cff0-7c1a-7d4c-f927a16c07c9@yandex.ru> <8b5f4961-f980-4971-50b7-4770205833ee@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="10094"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (darwin) To: emacs-devel@gnu.org Cancel-Lock: sha1:RqtHIaLzxWNEV/QS1Md6XIq2PrM= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Nov 18 19:57:10 2020 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 1kfSdi-0002Ux-8D for ged-emacs-devel@m.gmane-mx.org; Wed, 18 Nov 2020 19:57:10 +0100 Original-Received: from localhost ([::1]:40796 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kfSdh-0003a5-9e for ged-emacs-devel@m.gmane-mx.org; Wed, 18 Nov 2020 13:57:09 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:36140) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kfSaW-0001Uk-Cw for emacs-devel@gnu.org; Wed, 18 Nov 2020 13:53:54 -0500 Original-Received: from static.214.254.202.116.clients.your-server.de ([116.202.254.214]:47614 helo=ciao.gmane.io) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kfSaS-0006qc-Rv for emacs-devel@gnu.org; Wed, 18 Nov 2020 13:53:52 -0500 Original-Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1kfSaP-0008kZ-Ia for emacs-devel@gnu.org; Wed, 18 Nov 2020 19:53:45 +0100 X-Injected-Via-Gmane: http://gmane.org/ Received-SPF: pass client-ip=116.202.254.214; envelope-from=ged-emacs-devel@m.gmane-mx.org; helo=ciao.gmane.io X-detected-operating-system: by eggs.gnu.org: First seen = 2020/11/18 13:30:54 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: 5 X-Spam_score: 0.5 X-Spam_bar: / X-Spam_report: (0.5 / 5.0 requ) BAYES_00=-1.9, DKIM_ADSP_CUSTOM_MED=0.001, FORGED_GMAIL_RCVD=1, FREEMAIL_FORGED_FROMDOMAIN=0.249, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, NML_ADSP_CUSTOM_MED=0.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action 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:259379 Archived-At: Dmitry Gutov writes: > I'm not sure why prepend and not append, but I suppose it's a matter > of preference. In my case, some directory/file names are extremely long... But either way is fine. > Also, xref-location-line can return nil (then format will error out > because of %d). So after a little experimenting, this is the form I > ended up with: > > (format "%s:%s: %s" group line summary) Thanks for catching that. I didn't know that "%s" prints not only strings, but any types.. It would be nice if the change can be merged. Then I only need one line setting. -- William