Advertisement

Why lisp?

Started by January 31, 2004 10:00 PM
103 comments, last by Vlion 20 years, 11 months ago
quote:
Original post by Arild Fines
The best thing about Lisp is that all it's proponents are so humble.


You actually hit the nail on the head. This puts most newbies off Lisp completely and it's been written about quite often.

Why we hate Lisp

Smug Lisp Weenies

Social Problems of Lisp

It's just difficult discussing the merits of *any* language without coming across as "My C64 rules, your Spectrum sucks", "My Amiga rules, PeeCee sucks", "NVidia versus ATI". etc.

If you want to read a very balanced discussion on the merits of Lisp, try this Q/A session on Slashdot by Kent M Pitman. It's what got me interested in Lisp in the first place.

Kent M. Pitman Answers On Lisp And Much More

Kent M. Pitman's Second Wind

Things like being able to patch a Lisp program - while it is running - really blew me away.


[edited by - HairyTroll on February 19, 2004 1:18:10 PM]
quote:
Original post by Krippy2k
A good example of this would probably answer the original authors question, as well as mine. What would be a language extension that you could create in Lisp that you wouldnt even dream of doing in C++?
These are all pretty long to explain, so you''ll get best explanations by doing a search:
- continuations
- prolog/logic programming
- undeterministic programs
- pattern matching
- dynamic multiple dispatch (the visitor pattern can be seen as an ugly implementation of dynamic double dispatch, a limited version of multiple dispatch)
- aspect oriented paradigm (I''m not very knowledgeable of this, but from what I''ve heard it at least incorporates Design by Contract as seen in Eiffel)

These are of course just the more common things one might be interested in. The perhaps better and even more justified uses are highly task specific. E.g. you''ll start noticing unavoidable code duplication when writing GUI code using standard idioms. No worries, just extend the language to transform some compact representation of the GUI layout into code.
Advertisement
quote:
Original post by Krippy2k
A recent C/C++ Users Journal showed a reasonably simple way to add lambda functions to C++.
If it''s anything like the lambda seen in Boost (like I''d reasonably assume it to be), then that''s still *far* behind from the usefulness of Lisp''s lambda. What you gonna do with lambda when you got no closure?
quote:
Original post by Arild Fines
The best thing about Lisp is that all it''s proponents are so humble.

Makes you cringe doesn''t it?
Interesting.
I still don''t percieve any practical advantage Lisp has over .

I think that theres no good reason to write lisp over Prolog or .

Language theory aside- it seems to be needlessly simplified and with a minimum of constructs.

I know that is due to reasonable factors- don''t get me wrong, its a very "nice" language- but I think I''d sooner burn my time on Ruby and advanced C++ constructs and understand the procedural paradigm throughly. I''ve no beef with Lisp- it just takes way too long and too much kludging to get anywhere in terms of what I write: even if I''m doing logical types of questions.

Prolog seems to be a better "other" langauge, frankly.

*shrug*

Peace out.

~V''lion

Bugle4d
~V'lionBugle4d
quote:
Prolog seems to be a better "other" langauge, frankly.


Paul Graham has a Prolog language embedded in Lisp written in 180 lines in his "On Lisp" book. This should be the kind of example you''re looking for.
Advertisement
Another small example of sublanguage built on Lisp: the loop construct. This is available in Lisp, but it is coded as a set of macros - as an extension language: http://www.ai.sri.com/~pkarp/loop.html

I think a good example is the new object system created in the book ANSI Common Lisp. You might think its no big deal, since C++ has an object system too, but I think its nice that in Lisp you can make your own if you want. I don''t particularly like C++''s object system or CLOS, so if I were to ever become a serious lisp programmer one of the first things I''d probably do is make my own object system with the features I want and lacking the ones I don''t.
"Walk not the trodden path, for it has borne it's burden." -John, Flying Monk
quote:
Original post by Vlion
Interesting.
I still don''t percieve any practical advantage Lisp has over <good OO language>.
Sigh. The point is that you won''t find the set of features described in this thread from any other single language except Lisp. If you don''t believe those features have any practical advantage, that only shows your ignorance regarding those features. You''re like a C++ newbie who can''t yet use classes and wonders what use they have over the convenient C structs. If you''re not interested in researching a bit on the topics, nobody will be able to convince you. We''ve already presented a bunch of stuff Lisp can do that most other languages can''t, yet you keep on insisting that Lisp has no practical advantage. Is that really logical at all? I mean, what would make Lisp have a practical advantage in your eyes?
quote:
Original post by Krippy2k
Lisp lacks much of the powerful functionality provided by the STL...


Such as?

Honestly, from a quick glance at SGI''s STL site (link) I see little to nothing in the STL that isn''t either a part of Lisp or trivial to implement (and by trivial I mean a couple lines of code). The Common Lisp standard includes a LOT of useful stuff. Google for "Common Lisp Hyperspec" if you don''t know where to look.

And while I agree with you that the library of C++ code available out there dwarfs that of Lisp, in some areas that code accomplishes something that is largely unnecessary in Lisp (as a couple of examples how about scripting languages, and just about anything related to XML).

--- end of smug Lisp weenie post ---

Disclaimer: I''m not a zealot but I do like Lisp. It just strikes me that your assertion about Lisp and the STL is just plain wrong and probably coming from ignorance.

This topic is closed to new replies.

Advertisement