From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Daniel Colascione Newsgroups: gmane.emacs.devel Subject: Re: eval-after-load not harmful after all (Was: Re: Why js-2mode?) Date: Mon, 10 Aug 2009 23:06:41 -0400 Message-ID: <1D8E5A42-FE2C-4B54-B189-C6EAC4A0D47E@merrillpress.com> References: <7b501d5c0908091634ndfba631vd9db6502db301097@mail.gmail.com> <998B83F771474211A37D1E2B6A497B61@us.oracle.com> <878whr9o4c.fsf@uwakimon.sk.tsukuba.ac.jp> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v936) Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1249960024 19510 80.91.229.12 (11 Aug 2009 03:07:04 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 11 Aug 2009 03:07:04 +0000 (UTC) Cc: 'CHENG Gao' , 'Carsten Dominik' , 'Leo' , Drew Adams , emacs-devel@gnu.org To: Stephen J. Turnbull Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 11 05:06:56 2009 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MahhP-0006hk-K0 for ged-emacs-devel@m.gmane.org; Tue, 11 Aug 2009 05:06:55 +0200 Original-Received: from localhost ([127.0.0.1]:58452 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MahhO-0000JX-GH for ged-emacs-devel@m.gmane.org; Mon, 10 Aug 2009 23:06:54 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MahhJ-0000JI-K5 for emacs-devel@gnu.org; Mon, 10 Aug 2009 23:06:49 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MahhF-0000Hs-SA for emacs-devel@gnu.org; Mon, 10 Aug 2009 23:06:49 -0400 Original-Received: from [199.232.76.173] (port=33068 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MahhF-0000Hn-MZ for emacs-devel@gnu.org; Mon, 10 Aug 2009 23:06:45 -0400 Original-Received: from vpn.merrillpress.com ([64.61.107.78]:46490) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MahhF-0002UA-4X for emacs-devel@gnu.org; Mon, 10 Aug 2009 23:06:45 -0400 Original-Received: from cpe-67-246-181-235.buffalo.res.rr.com ([67.246.181.235] helo=[192.168.1.103]) by mars.merrillpress.net with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.63) (envelope-from ) id 1MahhC-0006Vy-UA; Mon, 10 Aug 2009 23:06:43 -0400 In-Reply-To: <878whr9o4c.fsf@uwakimon.sk.tsukuba.ac.jp> X-Mailer: Apple Mail (2.936) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:114018 Archived-At: On Aug 10, 2009, at 8:43 PM, Stephen J. Turnbull wrote: > Drew Adams writes: >> In Icicles, I sometimes `require' other libraries explicitly. But >> in a few cases >> I use `eval-after-load' instead - for exactly the kind of thing >> that Carsten >> described. >> >> I agree with Daniel, Carsten, and others that `eval-after-load' >> should not be >> demonized. > > I have no objection to use of `eval-after-load' in user or site files > that are disabled by emacs -q. But `eval-after-load' in core files is > like smoking in an elevator next to a pregnant woman. It's very > convenient, maybe even "necessary", from the point of view of the > user of the feature, but he doesn't bear the pain of debugging a > Heisenbug that appears for the user of random-package-using-e-a-l. You haven't actually addressed the reason for using e-a-l and provided alternatives, nor have you provided any concrete examples of the harm e-a-l might cause. You've just put "necessary" in scare quotes without even considering the idea that it might actually *be* necessary. If packages M needs to work with optional package Q, then there are two approaches: either M can use eval-after-load to customize Q, or Q can include a list of every possible M with which it can be used. You might decry the former, but I don't think the latter is any more maintainable.