From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/62647 Path: news.gmane.org!not-for-mail From: Dave Love Newsgroups: gmane.emacs.devel,gmane.emacs.gnus.general Subject: Re: use of (defvar ) Date: Tue, 11 Apr 2006 18:06:55 +0100 Message-ID: References: <87lkuhdsyb.fsf-monnier+emacs@gnu.org> <87bqvas2ls.fsf-monnier+emacs@gnu.org> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1144775331 22569 80.91.229.2 (11 Apr 2006 17:08:51 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 11 Apr 2006 17:08:51 +0000 (UTC) Cc: ding@gnus.org, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Apr 11 19:08:48 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FTMLz-00032v-FR for ged-emacs-devel@m.gmane.org; Tue, 11 Apr 2006 19:08:35 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FTMLy-0003Iy-Vw for ged-emacs-devel@m.gmane.org; Tue, 11 Apr 2006 13:08:34 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FTMKX-0002HM-Q1 for emacs-devel@gnu.org; Tue, 11 Apr 2006 13:07:05 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FTMKW-0002G9-0W for emacs-devel@gnu.org; Tue, 11 Apr 2006 13:07:05 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FTMKV-0002G3-PF for emacs-devel@gnu.org; Tue, 11 Apr 2006 13:07:03 -0400 Original-Received: from [217.158.120.143] (helo=mail.ukfsn.org) by monty-python.gnu.org with esmtp (Exim 4.52) id 1FTMPP-00042F-EZ for emacs-devel@gnu.org; Tue, 11 Apr 2006 13:12:07 -0400 Original-Received: from localhost (84-45-211-153.no-dns-yet.enta.net [84.45.211.153]) by mail.ukfsn.org (Postfix) with ESMTP id CCCD4E6F3A; Tue, 11 Apr 2006 18:03:41 +0100 (BST) Original-Received: from fx by localhost with local (Exim 4.60) (envelope-from ) id 1FTMKT-0002oL-9U; Tue, 11 Apr 2006 18:07:01 +0100 Original-To: Stefan Monnier X-Draft-From: ("nnml:Misc" 429) In-Reply-To: <87bqvas2ls.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Sun, 09 Apr 2006 20:29:53 -0400") User-Agent: Gnus/5.11 (Gnus v5.11) 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:52694 gmane.emacs.gnus.general:62647 Archived-At: Stefan Monnier writes: >> Huh? You don't want it compiled -- that's the point. [Actually, I meant the code rather than the eval result.] > By "compiled" I only mean that it goes through the byte-compiler (before > being eval'd). It goes through the compiler _after_ being evalled, by definition. > If the content of eval-when-compile were not compiled, then > (eval-when-compile (defvar foo)) would be 100% equivalent to a nop. But it isn't compiled as such. > Compiling the content of eval-when-compile before eval'ing doesn't > remove/hide any bug AFAIK, quite the opposite. Doing that would be a bug. If the effect of the defvar on load-history has been redefined as a bug, the eval-when-compile wrapper does avoid a bug, and I don't see how it could reasonably be harmful in a future Emacs. CL's `(declare (special ...))' often is cleaner, though.