I feel for the author and have recently come to a similar (read: not same ) conclusion: Lisp is pretty crappy for maybe 90% of the work being done out there. The more easily-accessible and popular a domain is, the worse Lisp will be for it. This isn't because Lisp magically gets worse; it's because other languages get better , through libraries. Even if nine of ten libraries are crappy, there are enough people in the…
What's Special About Lisp?
21–30 of 69 posts
Re: What's Special About Lisp?
#22"homoiconicity": the property of a language whereby code written in said language is stored, in a natural and immediate fashion, as a data structure of the same language
What this means for Lisp is that if you want to manipulate Lisp code, you aren't dealing with some crazy complex AST: you can actually /see/ how the code is parsed by looking at the code itself, as the code is actually typed using the serialization format for the primary data structure of the language: S-expressions.
So, you aren't just creating a little "DSL" by using some built-in syntax tricks like "implicit last argument block", but instead are able to write code that modifies code and generates code as easily as if you were writing the original code in the first place: the comparison to Ruby is therefore fundamentally flawed.
(Finally, as an unrelated bonus: the parser for Lisp is also written in Lisp and available during the execution of Lisp, so you can have code that modifies and extends the parser itself allowing you to fundamentally alter the syntax to, for example, look like Ruby; this mechanism is called "reader macros", for the record.)
Re: What's Special About Lisp?
#23I feel for the author and have recently come to a similar (read: not same ) conclusion: Lisp is pretty crappy for maybe 90% of the work being done out there. The more easily-accessible and popular a domain is, the worse Lisp will be for it. This isn't because Lisp magically gets worse; it's because other languages get better , through libraries. Even if nine of ten libraries are crappy, there are enough people in the…
well, if it's a language for writing libraries - why there are no libraries? :)
Actually, "library" is probably the wrong word for reused Lisp code. A library is a public thing, an institution---and all that goes with it: slow to change, must be easy to understand, etc.
Instead of libraries, Lisp hackers have private collections. Like a messy desk, they are often supremely useful once you get the hang of it, but are inscrutable to others. Not exactly the best characteristics to get popular on github.
Re: What's Special About Lisp?
#24I've created 3 libraries that I think would be exceedingly difficult, excruciating, or impossible to write with the performance and the level of control over syntax in anything but a very good Lisp:
http://github.com/clojure/core.logic, efficient embedded Prolog in 1K LOC
http://github.com/swannodette/match, in progress implementation of a state-of-the-art OCaml pattern matching algorithm
http://github.com/swannodette/delimc, delimited continuations
Re: What's Special About Lisp?
#25Re: What's Special About Lisp?
#26I do love ruby and feel that it's metaprogramming techniques to allow you to easily emulated many features of Lisp's macros. That said the author missing an obvious thing here. They key with macros is that they allow you to alter syntax (not calculate values as many who try initially misunderstand them), and s-exps are essential to being able to do this (because they are effectively an abstract syntax tree). I say th…
(Edited: awkward English.)
Re: What's Special About Lisp?
#27I feel for the author and have recently come to a similar (read: not same ) conclusion: Lisp is pretty crappy for maybe 90% of the work being done out there. The more easily-accessible and popular a domain is, the worse Lisp will be for it. This isn't because Lisp magically gets worse; it's because other languages get better , through libraries. Even if nine of ten libraries are crappy, there are enough people in the…
That said, why not try Clojure? Best of both worlds, and then some.
Re: What's Special About Lisp?
#28A ton of responses and no one mentions the one-word answer? "homoiconicity": the property of a language whereby code written in said language is stored, in a natural and immediate fashion, as a data structure of the same language What this means for Lisp is that if you want to manipulate Lisp code, you aren't dealing with some crazy complex AST: you can actually /see/ how the code is parsed by looking at the code its…
> instead are able to write code that modifies code and generates code as easily as if you were writing the original code in the first place
Is this often done? I know it is conceptually possible with the advantage being that the same functions used to manipulate lists and data are available for this task, but I got the impression that not many people actually do this? For instance...
http://stackoverflow.com/questions/6480053/modifying-functio...
Re: What's Special About Lisp?
#29A ton of responses and no one mentions the one-word answer? "homoiconicity": the property of a language whereby code written in said language is stored, in a natural and immediate fashion, as a data structure of the same language What this means for Lisp is that if you want to manipulate Lisp code, you aren't dealing with some crazy complex AST: you can actually /see/ how the code is parsed by looking at the code its…
Re: What's Special About Lisp?
#30That doesn't make sense, because there's no way to twist it. It's more work and duplication. I want macros all the time in JavaScript and that is a pretty flexible and dynamic language.
Most of Lisp's other features are common now. Macros are still a big one but you don't need them every day. Lisp has powerful exception handling but I'd rather have Erlang style error handling and recovery.
Lisp's draw is waning but only because our languages are lispy in ways that really matter. We have dynamic, garbage collection languages with REPLs and built in high level data structures that are even better because we have native syntax for them. I don't want to keep track of N different kinds of assoc lists... and I really like Lisp.