From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Re: Is (provide 'foo) at the start good or bad? Date: Fri, 12 Jun 2009 08:36:09 +0000 Message-ID: <20090612083609.GA2953@muc.de> References: <21glws7jx732.fsf@gmail.com> <87r5xqw0s8.fsf@uwakimon.sk.tsukuba.ac.jp> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1244795844 6619 80.91.229.12 (12 Jun 2009 08:37:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 12 Jun 2009 08:37:24 +0000 (UTC) Cc: Leo , emacs-devel@gnu.org To: "Stephen J. Turnbull" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jun 12 10:37:19 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 1MF2GD-0005ZQ-9k for ged-emacs-devel@m.gmane.org; Fri, 12 Jun 2009 10:37:19 +0200 Original-Received: from localhost ([127.0.0.1]:39120 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MF2GB-0008W9-2s for ged-emacs-devel@m.gmane.org; Fri, 12 Jun 2009 04:37:15 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MF2EN-0008Dl-V5 for emacs-devel@gnu.org; Fri, 12 Jun 2009 04:35:24 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MF2EI-0008CD-EU for emacs-devel@gnu.org; Fri, 12 Jun 2009 04:35:23 -0400 Original-Received: from [199.232.76.173] (port=58829 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MF2EI-0008C5-6s for emacs-devel@gnu.org; Fri, 12 Jun 2009 04:35:18 -0400 Original-Received: from colin.muc.de ([193.149.48.1]:2856 helo=mail.muc.de) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MF2EG-0001ru-4c for emacs-devel@gnu.org; Fri, 12 Jun 2009 04:35:17 -0400 Original-Received: (qmail 46852 invoked by uid 3782); 12 Jun 2009 08:34:56 -0000 Original-Received: from acm.muc.de (pD9E51C56.dip.t-dialin.net [217.229.28.86]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Fri, 12 Jun 2009 10:34:53 +0200 Original-Received: (qmail 3676 invoked by uid 1000); 12 Jun 2009 08:36:09 -0000 Content-Disposition: inline In-Reply-To: <87r5xqw0s8.fsf@uwakimon.sk.tsukuba.ac.jp> User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) X-Primary-Address: acm@muc.de X-detected-operating-system: by monty-python.gnu.org: FreeBSD 4.6-4.9 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:111448 Archived-At: Hi, Stephen, On Fri, Jun 12, 2009 at 01:09:43PM +0900, Stephen J. Turnbull wrote: > Leo writes: > > > one less char). So what is the benefit of providing it at the > > > very start? > > I have run into this problem before. I prefer putting provide at the > > end of the file. > Putting the provide form at the beginning allows mutually recursive > requires to succeed. I also prefer it as a matter of style, sort of > serving as a `declare-package'. Putting `provide' at the end of the file means you've actually loaded the file when the provision is done. Thus if the load crashes (very common when you're developing), you don't have a spurious provided symbol. Like in lots of things, there's no one Right Way to do it. -- Alan Mackenzie (Nuremberg, Germany).