From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: storm@cua.dk (Kim F. Storm) Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] New convenience macros Date: Mon, 20 Aug 2007 12:58:47 +0200 Message-ID: <87absmjwuw.fsf@kfs-lx.testafd.dk> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1187607558 21259 80.91.229.12 (20 Aug 2007 10:59:18 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 20 Aug 2007 10:59:18 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Aug 20 12:59:15 2007 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 1IN4yZ-0003Im-Gp for ged-emacs-devel@m.gmane.org; Mon, 20 Aug 2007 12:59:15 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IN4ya-0001p1-7g for ged-emacs-devel@m.gmane.org; Mon, 20 Aug 2007 06:59:16 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IN4yO-0001od-CD for emacs-devel@gnu.org; Mon, 20 Aug 2007 06:59:04 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IN4yK-0001o2-7q for emacs-devel@gnu.org; Mon, 20 Aug 2007 06:59:02 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IN4yJ-0001nx-GG for emacs-devel@gnu.org; Mon, 20 Aug 2007 06:58:59 -0400 Original-Received: from mail-relay.sonofon.dk ([212.88.64.25]) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1IN4yG-0000zV-Uk for emacs-devel@gnu.org; Mon, 20 Aug 2007 06:58:57 -0400 Original-Received: (qmail 78570 invoked from network); 20 Aug 2007 10:58:51 -0000 Original-Received: from unknown (HELO kfs-lx.testafd.dk.cua.dk) (213.83.150.2) by 0 with SMTP; 20 Aug 2007 10:58:51 -0000 In-Reply-To: (Steve Youngs's message of "Mon\, 20 Aug 2007 12\:06\:03 +1000") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux) X-Detected-Kernel: 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:76822 Archived-At: Steve Youngs writes: > NotDashEscaped: You need GnuPG to verify this message > > * Richard Stallman writes: > > > I don't want to contrast the name "XEmacs" with the name "GNU Emacs", > > so I don't want these macros installed in Emacs under the names > > proposed. > > How about.. `do-in-emacs', `do-in-xemacs', `do-in-sxemacs', and > `with-emacs-type', and change the symbol in `with-emacs-type' from `gnu' > to `emacs'. Would that be better? > > The names aren't that important, providing they are consistent across > the 3 emacs variants. I have no particular preference so I'm happy to > go with whatever names you decide, Richard. Just let me know what names > you do use for these macros so I can ensure the same goes into XEmacs > and SXEmacs. So far, there is code in Emacs which is XEmacs aware by testing on (if (featurep 'xemacs) ...) and the byte compiler being aware that this condition is always false in Emacs, so XEmacs code is ignored. We could arrange for to byte-compiler to know about (featurep 'sxemacs) as well, but I think that's as far as we should go in terms of differentiating yet another Emacs derivate. I suppose that SXEmacs also provides xemacs (or you will have to edit a lot of existing code!), so it is really only for the differences between SXEmacs and XEmacs that you may need additional sxemacs tests. I really don't see why Emacs has to be concerned about that. Next month somebody else will ask for support for TXEmacs. I could go as far as creating a new macro "when-emacs" that could be used as (when-emacs emacs ...) (when-emacs xemacs ...) (when-emacs sxemacs ...) which simply expands into (if (featurep (quote VARIANT)) BODY) And instead of just a fixed 'xemacs symbol in the byte compiler, there could be a list of features to ignore: (defvar byte-compiler-ignored-features '(xemacs sxemacs)) -- Kim F. Storm http://www.cua.dk