From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#20489: [Emacs-diffs] master d48e07a: * lisp/simple.el (next-error-find-buffer-function): New defcustom. Date: Fri, 23 Feb 2018 09:36:19 -0500 Message-ID: References: <20180221213025.27066.69339@vcs0.savannah.gnu.org> <20180221213027.372932052F@vcs0.savannah.gnu.org> <87r2pc7w60.fsf@mail.linkov.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1519396512 25217 195.159.176.226 (23 Feb 2018 14:35:12 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 23 Feb 2018 14:35:12 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: 20489@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Feb 23 15:35:07 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1epERG-0005xT-Ia for geb-bug-gnu-emacs@m.gmane.org; Fri, 23 Feb 2018 15:35:06 +0100 Original-Received: from localhost ([::1]:44941 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1epETI-0004Ha-Uh for geb-bug-gnu-emacs@m.gmane.org; Fri, 23 Feb 2018 09:37:12 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:57169) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1epETC-0004HO-NC for bug-gnu-emacs@gnu.org; Fri, 23 Feb 2018 09:37:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1epET8-0002ha-LQ for bug-gnu-emacs@gnu.org; Fri, 23 Feb 2018 09:37:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:49349) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1epET8-0002gz-Hc for bug-gnu-emacs@gnu.org; Fri, 23 Feb 2018 09:37:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1epET8-0002xG-5i for bug-gnu-emacs@gnu.org; Fri, 23 Feb 2018 09:37:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 23 Feb 2018 14:37:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 20489 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 20489-submit@debbugs.gnu.org id=B20489.151939658511313 (code B ref 20489); Fri, 23 Feb 2018 14:37:02 +0000 Original-Received: (at 20489) by debbugs.gnu.org; 23 Feb 2018 14:36:25 +0000 Original-Received: from localhost ([127.0.0.1]:57246 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1epESW-0002wO-Sz for submit@debbugs.gnu.org; Fri, 23 Feb 2018 09:36:25 -0500 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:50393) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1epEST-0002wE-CK for 20489@debbugs.gnu.org; Fri, 23 Feb 2018 09:36:23 -0500 Original-Received: from pastel.home (lechon.iro.umontreal.ca [132.204.27.242]) by chene.dit.umontreal.ca (8.14.7/8.14.1) with ESMTP id w1NEaJ7o007540; Fri, 23 Feb 2018 09:36:20 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id A0E0F6043C; Fri, 23 Feb 2018 09:36:19 -0500 (EST) In-Reply-To: <87r2pc7w60.fsf@mail.linkov.net> (Juri Linkov's message of "Thu, 22 Feb 2018 23:38:23 +0200") X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 2 Rules triggered EDT_SA_DN_PASS=0, RV6229=0 X-NAI-Spam-Version: 2.3.0.9418 : core <6229> : inlines <6431> : streams <1779815> : uri <2598011> 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: 208.118.235.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:143624 Archived-At: >> Could you arrange for the default value of this new *-function var not >> to be nil so we can modify it with add-function? > Then I guess the default function should return nil. Here is a new patch: Fine by me. Tho, see comments below. Stefan > +(defun next-error-find-buffer-function-default (&optional avoid-current > + extra-test-inclusive > + extra-test-exclusive)) This looks like a syntax error to me (function without body). I know it's accepted (because various parts of the byte-compiler need special hacks to deal with it), but please always put a body (i.e. an explicit nil). This said, I don't think you should define this function. Instead: > +(defvar next-error-find-buffer-function 'next-error-find-buffer-function-default should just say (defvar next-error-find-buffer-function #'ignore -- Stefan