From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#7236: 24.0.50; make-local-hook missing Date: Tue, 19 Oct 2010 12:32:12 -0400 Message-ID: References: <87y69vbyrk.fsf@mail.eng.it> <19644.32383.529459.435414@mail.eng.it> <20101018214207.GB3396@muc.de> <9D100A0D59D34365AD1993719B18D9D6@us.oracle.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1287507037 22018 80.91.229.12 (19 Oct 2010 16:50:37 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 19 Oct 2010 16:50:37 +0000 (UTC) Cc: 7236@debbugs.gnu.org, saint@eng.it To: "Drew Adams" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Oct 19 18:50:35 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1P8FOV-0002ar-69 for geb-bug-gnu-emacs@m.gmane.org; Tue, 19 Oct 2010 18:50:35 +0200 Original-Received: from localhost ([127.0.0.1]:43217 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P8FOU-0002kE-Di for geb-bug-gnu-emacs@m.gmane.org; Tue, 19 Oct 2010 12:50:34 -0400 Original-Received: from [140.186.70.92] (port=55115 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P8FGp-0005qn-7G for bug-gnu-emacs@gnu.org; Tue, 19 Oct 2010 12:42:55 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1P8FGk-0005Pr-NP for bug-gnu-emacs@gnu.org; Tue, 19 Oct 2010 12:42:35 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:60364) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1P8FGk-0005Pl-La for bug-gnu-emacs@gnu.org; Tue, 19 Oct 2010 12:42:34 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1P8F3e-0002Av-Hv; Tue, 19 Oct 2010 12:29:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 19 Oct 2010 16:29:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 7236 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 7236-submit@debbugs.gnu.org id=B7236.12875057128349 (code B ref 7236); Tue, 19 Oct 2010 16:29:02 +0000 Original-Received: (at 7236) by debbugs.gnu.org; 19 Oct 2010 16:28:32 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1P8F3A-0002Ac-1a for submit@debbugs.gnu.org; Tue, 19 Oct 2010 12:28:32 -0400 Original-Received: from pruche.dit.umontreal.ca ([132.204.246.22]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1P8F38-0002AX-2e for 7236@debbugs.gnu.org; Tue, 19 Oct 2010 12:28:30 -0400 Original-Received: from faina.iro.umontreal.ca (vpn-132-204-232-65.acd.umontreal.ca [132.204.232.65]) by pruche.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id o9JGWDd6028637; Tue, 19 Oct 2010 12:32:13 -0400 Original-Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id 9ED94B4007; Tue, 19 Oct 2010 12:32:12 -0400 (EDT) In-Reply-To: <9D100A0D59D34365AD1993719B18D9D6@us.oracle.com> (Drew Adams's message of "Mon, 18 Oct 2010 19:15:59 -0700") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV3653=0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Tue, 19 Oct 2010 12:29:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) 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: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:40992 Archived-At: >> No: m-l-h is also unnecessary when add-hook is called with a nil LOCAL >> argument. I know of no case where calling make-local-hook makes >> a difference in Emacs>=21. > In Emacs 20 also there is a LOCAL optional arg to add-hook. Yes, but its semantics is slightly different: it means "put it on the local part of the hook, but only if that local part exists". I.e. it's only effective if make-local-hook has been called before. I changed this in Emacs-21 (it an incompatible change, but didn't cause any bug report AFAIR) which made make-local-hook a NOP. > Should all code for Emacs 20-24 remove make-local-hook calls and > instead add `t' to an existing call to add-hook? No. If the LOCAL arg is nil, add-hook will only affect the global part of the hook, regardless of whether make-local-hook has been called. Stefan