Re: How Common Lisp sucks
- From: Pascal Bourguignon <pjb@xxxxxxxxxxxxxxxxx>
- Date: Wed, 19 Apr 2006 04:06:46 +0200
spammer@xxxxxxxxxxxxxxxxxxxxx (Jyri J. Virkki) writes:
In article <87zmijlee3.fsf@xxxxxxxxxxxxxxxxxxxxxxxxxx>,
Pascal Bourguignon <pjb@xxxxxxxxxxxxxxxxx> wrote:
Ron Garret <rNOSPAMon@xxxxxxxxxxx> writes:
Cross-compiler portability for C and C++ is pretty good. It's even
pretty good for CL as long as you don't have to interface with the
outside world, which is exactly the problem.
I don't think so. Try to link a library compiled for the Darwin/ppc
virtual machine with your program compiled for the Linux/x86 virtual
machine.
I can't tell if this response was just meant to be silly or not;
apologies if misunderstood. I bet the original poster meant source
portability, not attempting to link shared objects from different
platforms into one executable..
Yes, I was answering to the general meaning of the message, not
necessarily to the exact formal sentences.
What I mean is that people find that it's easy to link and use
libraries with their C programs, and then are surprised that it may
not be so easy to use libraries in various CL implementations. Ron
expressed this.
The reason is that while the C "environment" is one "virtual" machine,
where all the libraries and compilers are integrated into it, each of
the CL implementation is its own "virtual" machine. Even CL compilers
that target a native processor still have a garbage collector and data
structure formats that are totally different from those of the
programming language implementations that target vanilla OS/processor
"virtual" machine. This explains why library interoperability is hard
between CL implementations, and why library interoperability is hard
between a given CL implementation and the other common "virtual"
machines.
We may have good FFI (Clisp FFI or CFFI), but we cannot use directly C
headers because the semantics are incompatible: we need to hand-write
the FFI definitions to do the gateway. C libraries cannot directly
use our data, we need to translate it for them because they target the
standard OS/processor "virtual" machines instead of targeting the
"Lisp Machines" on which CL implementations run.
Actually, this is the same kind of problems with have with the
different object models. You cannot easily use Objective-C libraries
with Eiffel, ObjectPascal, Java or C++, because they target different
"virtual" machines, even if they run on the same processor. Sometimes
you can use C as a gateway between objects written in different
languages (eg ObjC++), but that's all.
[...]
And yet it is not a problem with Java (or perl/python/ruby/..). In my
free time I sometimes write code for friends, some of whom run windows
(they are decent people otherwise). As I don't own any windows
machines at home, I write such code in Java, compile it into class
files on either Linux, Solaris or OS X and send the jar files to
friends who run the applications on windows. It Just Works. Is there
any way I can pull this off using lisp? (Serious question, I'd love to try!)
Well, you could use ABCL, which targets the JVM.
Another solution would be to define a LVM and implement it ubiquituously.
None of this is meant to detract from lisp. Lisp is fun and I'm
enjoying it a lot. But if we're going to compare languages, it's good
to be objectively honest about the facts. Some of the problems with
lisp are non-issues in other languages. Of course it cuts both ways,
obnoxious problems in other languages can become non-issues in lisp.
--
__Pascal Bourguignon__ http://www.informatimago.com/
Small brave carnivores
Kill pine cones and mosquitoes
Fear vacuum cleaner
.
- References:
- How Common Lisp sucks
- From: Ron Garret
- Re: How Common Lisp sucks
- From: Dmitry Gorbatovsky
- Re: How Common Lisp sucks
- From: Ron Garret
- Re: How Common Lisp sucks
- From: Pascal Bourguignon
- Re: How Common Lisp sucks
- From: Jyri J. Virkki
- How Common Lisp sucks
- Prev by Date: Re: How Common Lisp sucks
- Next by Date: Re: How Common Lisp sucks
- Previous by thread: Re: How Common Lisp sucks
- Next by thread: Re: How Common Lisp sucks
- Index(es):
Relevant Pages
|