4 ms·
Lisp is 64 years old. In some ways its reputation is oversold. A lot of features (GC, varargs, lexical scope, closures, higher-order functions, dynamic method d
by erik_seaberg 4y ago
Lisp is 64 years old. In some ways its reputation is oversold. A lot of features (GC, varargs, lexical scope, closures, higher-order functions, dynamic method dispatch, reflection) first gained prominence in Lisp, despite being extravagantly expensive. Some optimizations were found, computers became vastly more powerful, and now those innovations are merely table stakes for any modern language.
IMHO the biggest exception is macros. Lisp isn’t the only language that has them, but it’s still the easiest by far if you ever want a domain-specific language to concisely express some problem. The grammar of its special forms is simple enough that we can easily use the symbol and linked-list builtins to generate boilerplate expressions or functions for the compiler without fighting with in-memory parse tree nodes or generating entire files of syntactically valid source.
- stingraycharles 4y agoFor me the most “woa” thing about LISP and its macros is that code is data, and data is code. The representation of a (nested) list is exactly the same as actual code, and using macros, I can manipulate it as such. That is pretty profound, and I still have yet to find a language that just makes it so simple and elegant as with LISP.
- hajile 4y agoInteractive, live development in Common Lisp is also basically unknown outside of maybe smalltalk. Stuff like "hot reload" in Javascript development is not at all comparable.
- qohen 4y agoIf one is interested in Lisp macros, btw, a good (and quite readable) book that covers the subject is On Lisp [0], by Paul Graham. You can download it as a PDF from the author's site[1]. P.S. If you're looking for Lisp enlightenment experiences, actually read through the code snippets in the book -- spending a few minutes staring at 5 lines of macro code and then having understanding dawn on you will give you some of those experiences (at least in the small) :-) [0] http://www.paulgraham.com/onlisp.html http://www.paulgraham.com/onlisp.html [1] http://www.paulgraham.com/onlisptext.html http://www.paulgraham.com/onlisptext.html