System specific coding by (excessive?) use of *features*

Heiko Kirschke <[email protected]> Mon, 18 Apr 2005 10:06:10 +0200
Newsgroups gmane.lisp.plob.general
Message-ID <[email protected]>
All,

when working on Plob's new version 2.11, I observe that I'm using
a lot of constructs like:

#-(or :lispworks4 :allegro-v7.0)
<do something>
#+(or :lispworks4 :allegro-v7.0)
<do something else>

I'm not very satisfied with this, since the #- and #+ expressions do not
express what I want (and, BTW, the code tends to become rather ugly by
using that construct). My goal is that I want small code changes which
adapt Plob's code to the different Lisp versions which might be in use.
These small changes have the nature that it does not make sense to introd=
uce
a new API for them (hiding the system specific implementation details) or
it is even not possible to make an API for that (e.g., system specific=20
(declare ...)
statements). So I often face the problem that I want something like ,,use
this piece of code for that Lisp system version x and probably later''.
In Allegro, there is the #+(version>=3D <number>) construct which is quit=
e
handy, but it is not available for LispWorks, so this makes it difficult =
for
using it at all in Plob's code. Is there some other portable construct wh=
ich
might solve this problem? Or is there maybe some other approach on
multi-system Lisp code that I'm not aware of?

Viele Gr=FC=DFe,
Heiko


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=3D6595&alloc_id=3D14396&op=3Dclick