From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.devel Subject: Re: tags-loop-continue Date: Fri, 22 Jan 2016 13:13:20 +0300 Message-ID: <56A200C0.1010309@yandex.ru> References: <83wprimto9.fsf@gnu.org> <83oacumqmj.fsf@gnu.org> <56917246.1010800@yandex.ru> <5691795E.9010008@yandex.ru> <83lh7ym725.fsf@gnu.org> <5691D768.3020908@yandex.ru> <83bn8tmnvq.fsf@gnu.org> <56928356.2000609@yandex.ru> <8360z1mkfc.fsf@gnu.org> <5696EE9D.2090708@yandex.ru> <838u3si22k.fsf@gnu.org> <5697C7A8.6060601@yandex.ru> <83wprcgjxk.fsf@gnu.org> <5697DA3B.3070706@yandex.ru> <83io2wggh8.fsf@gnu.org> <5697EC73.6040302@yandex.ru> <83fuy0gf2j.fsf@gnu.org> <5697F3C9.5040702@yandex.ru> <83bn8ogd8c.fsf@gnu.org> <56980073.7050604@yandex.ru> <838u3rhpzk.fsf@gnu.org> <569D3ADC.5060803@yandex.ru> <83si1sa47q.fsf@gnu.org> <56A0659F.1010306@yandex.ru> <83si1q987x.fsf@gnu.org> <56A11160.2010309@yandex.ru> <83k2n2964e.fsf@gnu.org> <56A12A4B.7030609@yandex.ru> <838u3i92n1.fsf@gnu.org> <56A12D6D.7080504@yandex.ru> <837fj29057.fsf@gnu.org> <56A13C75.4030606@yandex.ru> <83zivy7jq5.fsf@gnu.org> <56A14B00.1090207@yandex.ru> <56A14D05.7070807@yandex.ru> <83y4bi6qws.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1453457613 3365 80.91.229.3 (22 Jan 2016 10:13:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 22 Jan 2016 10:13:33 +0000 (UTC) Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jan 22 11:13:33 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aMYii-0001JP-Ln for ged-emacs-devel@m.gmane.org; Fri, 22 Jan 2016 11:13:32 +0100 Original-Received: from localhost ([::1]:52287 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMYih-0008WD-VQ for ged-emacs-devel@m.gmane.org; Fri, 22 Jan 2016 05:13:31 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54256) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMYie-0008Un-7g for emacs-devel@gnu.org; Fri, 22 Jan 2016 05:13:28 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aMYiZ-0002sx-7J for emacs-devel@gnu.org; Fri, 22 Jan 2016 05:13:28 -0500 Original-Received: from mail-lf0-x236.google.com ([2a00:1450:4010:c07::236]:36203) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMYiY-0002sP-T2; Fri, 22 Jan 2016 05:13:23 -0500 Original-Received: by mail-lf0-x236.google.com with SMTP id h129so44325485lfh.3; Fri, 22 Jan 2016 02:13:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-type:content-transfer-encoding; bh=pAHbQADklMJiCs4FSTFYrT27y3iHvKfOxOHWZvF9p68=; b=uhiCtOYS1u6R5t9SeqBolf1DGuDDoCwo3bI+8M5J5orxwiATcsbwO+fB8DthGtji7t /EF9aPnEPjmqNrspDNDaf4eFWtGCT7DWAiDnKKqWpGzDnSeAr9Oe0vP0DBG+az+YNgP+ byM/LOdEG5v1fWCYa+F1+xSgdRC/clhe8ZMifigFiDRT82cgP5C9aKh+RAQECZyb28/a sb9mtEEiUQWraZeeOOMDcQ0imSpYOSRu8HJy0AnS4AwUvbjrDrv2kdyxSZiwNHqQaXRA CFE4qKeMQNj79xc8H46BDe5fw8GWeJQ2P7qc1+MCDBfmGtYQIfeSinwIrNpNifm7Wyo4 cotA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:subject:to:references:cc:from:message-id :date:user-agent:mime-version:in-reply-to:content-type :content-transfer-encoding; bh=pAHbQADklMJiCs4FSTFYrT27y3iHvKfOxOHWZvF9p68=; b=DnOrld9uAtU/cwd84rn3iHQ6to4rGAT5pKPnvCEB4EXdoGkRxIY4ywEuo/1OB9jhQ0 rNSfEF/U476cqfuEryF3alVLQ7gzgTBqLpbpFXMc6Agb/G4sjgJlq7OjsHJzAZ00+zel qb26TX2BSXP10o4LhMuFQbU6zMM5Eaa/WtBpUTvZXzMUIAnTvBIazTIwKXrNNh+ZvJCt mvyk6Z4V7KuqrarN4MCv4eBc7z8IVYOpvqNrpTElXk3DEJUAo7xQ6AKytYeN0GI2pvZ5 kfiDSFNy7lv0TlncgEJhZ9HotugKBB3jm5rNHgJjLoEI/uSKvaSQuBzGR3gf5hgU7bYn ApWA== X-Gm-Message-State: AG10YOSrI/fOgHnsEDhQLH2rp6Hfvf0AYWw96DeXeXaInuUPhNDfej/2HcIZ7hlyKeoLMA== X-Received: by 10.25.159.211 with SMTP id i202mr896331lfe.145.1453457602172; Fri, 22 Jan 2016 02:13:22 -0800 (PST) Original-Received: from [192.168.1.190] ([178.252.127.222]) by smtp.googlemail.com with ESMTPSA id 99sm795703lfp.30.2016.01.22.02.13.20 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 22 Jan 2016 02:13:21 -0800 (PST) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:44.0) Gecko/20100101 Thunderbird/44.0 In-Reply-To: <83y4bi6qws.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:4010:c07::236 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:198570 Archived-At: On 01/22/2016 09:59 AM, Eli Zaretskii wrote: >> And if someone asks for it back, ask them to go fix bug#20489 first. > > I was about to suggest this myself. So yes, let's do that. If we > indeed try harder to leave the *xref* buffer visible, the need for > this integration would be lower. On the other hand, while *xref* is visible, `next-error' will keep working for its results (it's item 1 in next-error-find-buffer). That's how `next-error' stayed useful for e.g. *compilation* all these years. And it's fairly handy to call `next-error' to go to the next result, without having to switch back to *compilation*. So, do we really remove the integration? Up to you. diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index 2bccd85..1d71d24 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -600,22 +600,8 @@ xref--xref-buffer-mode-map (define-derived-mode xref--xref-buffer-mode special-mode "XREF" "Mode for displaying cross-references." (setq buffer-read-only t) - (setq next-error-function #'xref--next-error-function) (setq next-error-last-buffer (current-buffer))) -(defun xref--next-error-function (n reset?) - (when reset? - (goto-char (point-min))) - (let ((backward (< n 0)) - (n (abs n)) - (xref nil)) - (dotimes (_ n) - (setq xref (xref--search-property 'xref-item backward))) - (cond (xref - (xref--pop-to-location xref)) - (t - (error "No %s xref" (if backward "previous" "next")))))) - (defun xref-quit (&optional kill) "Bury temporarily displayed buffers, then quit the current window.