From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/81191 Path: news.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.gnus.general Subject: Re: Emacs version compatibility Date: Thu, 02 Feb 2012 13:32:45 +0100 Message-ID: <87pqdx76vm.fsf@gnus.org> References: <871uqey9t4.fsf@gnus.org> <87k445ptt5.fsf@marauder.physik.uni-ulm.de> <877h057ejp.fsf@gnus.org> <87r4ydms6b.fsf@gmx.de> <87boph33v2.fsf@gnus.org> <87bophmnff.fsf@gmx.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1328185989 1536 80.91.229.3 (2 Feb 2012 12:33:09 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 2 Feb 2012 12:33:09 +0000 (UTC) Cc: ding@gnus.org To: Michael Albinus Original-X-From: ding-owner+M29472@lists.math.uh.edu Thu Feb 02 13:33:08 2012 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Rsvqa-0006c7-9j for ding-account@gmane.org; Thu, 02 Feb 2012 13:33:04 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1RsvqT-00054K-Ph; Thu, 02 Feb 2012 06:32:57 -0600 Original-Received: from mx1.math.uh.edu ([129.7.128.32]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1RsvqS-00054C-Qx for ding@lists.math.uh.edu; Thu, 02 Feb 2012 06:32:56 -0600 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx1.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.76) (envelope-from ) id 1RsvqR-0000PX-Om for ding@lists.math.uh.edu; Thu, 02 Feb 2012 06:32:56 -0600 Original-Received: from hermes.netfonds.no ([80.91.224.195]) by quimby.gnus.org with esmtp (Exim 4.72) (envelope-from ) id 1RsvqP-0007wr-SM for ding@gnus.org; Thu, 02 Feb 2012 13:32:53 +0100 Original-Received: from 93-41-188-50.ip82.fastwebnet.it ([93.41.188.50] helo=rusty) by hermes.netfonds.no with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1RsvqJ-0004WO-VV; Thu, 02 Feb 2012 13:32:48 +0100 In-Reply-To: <87bophmnff.fsf@gmx.de> (Michael Albinus's message of "Thu, 02 Feb 2012 13:26:12 +0100") User-Agent: Gnus/5.130002 (Ma Gnus v0.2) Emacs/24.0.93 (gnu/linux) X-MailScanner-ID: 1RsvqJ-0004WO-VV MailScanner-NULL-Check: 1328790768.433@U9dYX5IvW0PEINiEyjDiEg X-Spam-Status: No X-Spam-Score: -1.9 (-) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:81191 Archived-At: Michael Albinus writes: > Sure. First step into this direction could be a modularization of that > compat library into compat22.el, compat23.el, xcompat.el. I was thinking the opposite. :-) All the items should check explicitly for whatever they want to do, and not rely on Emacs versions at all. That is, if you want to have `help-function-arglist' defined, then check whether it's undefined, and then define it. If you want a recursive `delete-directories', then check the version of that function that's installed, and if it's not satisfactory, then define a version that is. So this would be orthogonal to the Emacs versions. (Well, sort of. The function (re)definitions wouldn't necessarily work on all Emacs versions that have ever been, so they need to check whether they can actually do what they're trying to do. Or give up. Like this: (when (and (not (fboundp 'help-function-arglist)) (fboundp 'function-arglist)) (defun help-function-arglist (def &optional preserve-names) )) So if you're on an Emacs that doesn't even have `function-arglist', then you won't get this function. -- (domestic pets only, the antidote for overdose, milk.) http://lars.ingebrigtsen.no * Sent from my Rome