From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Carsten Dominik Newsgroups: gmane.emacs.devel Subject: Re: Question Date: Sat, 3 Jul 2010 07:38:44 +0200 Message-ID: <5007B929-B759-4728-9BE0-E2DAEACA7509@gmail.com> References: <877hlexg2l.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 Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1278135545 13327 80.91.229.12 (3 Jul 2010 05:39:05 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 3 Jul 2010 05:39:05 +0000 (UTC) Cc: Dan Davison , Eric Schulte , Emacs developers To: Stephen J. Turnbull Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jul 03 07:39:04 2010 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.69) (envelope-from ) id 1OUvRO-0004jF-5C for ged-emacs-devel@m.gmane.org; Sat, 03 Jul 2010 07:39:02 +0200 Original-Received: from localhost ([127.0.0.1]:44428 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OUvRN-0003Ia-I7 for ged-emacs-devel@m.gmane.org; Sat, 03 Jul 2010 01:39:01 -0400 Original-Received: from [140.186.70.92] (port=35199 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OUvRD-0003I8-Mx for emacs-devel@gnu.org; Sat, 03 Jul 2010 01:38:52 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OUvRC-0007ny-GC for emacs-devel@gnu.org; Sat, 03 Jul 2010 01:38:51 -0400 Original-Received: from mail-ew0-f41.google.com ([209.85.215.41]:50883) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OUvRC-0007nr-Bp for emacs-devel@gnu.org; Sat, 03 Jul 2010 01:38:50 -0400 Original-Received: by ewy28 with SMTP id 28so1398534ewy.0 for ; Fri, 02 Jul 2010 22:38:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:cc:message-id:from:to :in-reply-to:content-type:content-transfer-encoding:mime-version :subject:date:references:x-mailer; bh=+HbTEk3DpPqU9SVR3sI8doC75tR7cFcvY7bFJbsyuEs=; b=v9GEc9P9Wo0Y9bzM413cCfATDURYF5hjpjaUUbXubrbhNM3Fi5gzddtA0+gkTirZYJ rZsroTJnLb0pH2Ssf9gRojcx5+M42SrwzU7tMmZLdaOR4hyZG3ttgFs4lY8ne97pyCC8 Jy+Kd0QB9S6Bqz+WNZSNcLRl1RMcaK6u8dUxo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=cc:message-id:from:to:in-reply-to:content-type :content-transfer-encoding:mime-version:subject:date:references :x-mailer; b=BKE8iHoKlDBHRlEauly4VWURYADS41nv69sDVLRKiexhIHPbMy/op3tXxFE/7BiPt8 u6Xb0HpW1ph+mx3JTEF4V0KHftmzfJPzD98wltPGUReIJX/Qgf0DQwX30p968lLAUlJ/ u5dpFbgIho6yPt2qCShwABgGSiBErJ36wobVc= Original-Received: by 10.213.108.69 with SMTP id e5mr1534469ebp.39.1278135529003; Fri, 02 Jul 2010 22:38:49 -0700 (PDT) Original-Received: from [192.168.1.11] (dc5146846e.adsl.wanadoo.nl [81.70.132.110]) by mx.google.com with ESMTPS id v59sm12261420eeh.22.2010.07.02.22.38.45 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 02 Jul 2010 22:38:46 -0700 (PDT) In-Reply-To: <877hlexg2l.fsf@uwakimon.sk.tsukuba.ac.jp> X-Mailer: Apple Mail (2.936) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) 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:126720 Archived-At: OK, thanks for the input everyone. We'll think about and implement appropriate solutions. Looking at the files again, I actually think that we can make them compile with a small number of declare-function statements. Thanks! - Carsten On Jul 2, 2010, at 1:45 PM, Stephen J. Turnbull wrote: > Carsten Dominik writes: > >> For supporting different languages, we will have a few emacs lisp >> files which should not be compiled because the have dependencies on >> code that is not present in Emacs. I.e. they do something like >> >> (require 'slime) > > This is not a problem, unless it's within `eval-when-compile'. Go > ahead and compile it otherwise. > >> and call lots of functions from this package. > > For *functions*, this isn't a problem, either. However, *macros* from > the slime library must be defined at compile time, because Emacs byte > code doesn't know how to expand and reevaluate macros. (IIRC, anyway, > for sure XEmacs's bytecode interpreter can't do that.) Instead, the > macro is expanded, then the expansion is compiled at compile time. > >> I think the best way it to leave these files uncompiled. > > I feel sick ... ok, it got better. No, this is rarely a good idea. > If you have only functions, it's pointless. If you have macros, then > remember that macros get evaluated twice: once to generate code, and > once to evaluate the generated code. The function that generates the > expansion is rarely very efficient because it is expected to be > expanded once at compile time. Instead it is normally written to be > as straightforward an expression of the desired expansion code as > possible. IOW, you're likely to impose a perceptible performance hit > on those users. > > Since org-mode is now part of Emacs, third party packages can assume > it will be available, and if leaving files uncompiled seems your only > option, then it's probably best all-around to contribute that code to > the third-party package, and have it compiled there. >