Factor Language Blog

Most people who criticize Lisp don't understand it

Thursday, November 16, 2006

Disclaimer: I don’t program in Common Lisp these days and I don’t claim to speak for the Lisp community at all, however I think I do know the Lisp language reasonably well.

Just looking the last few weeks of postings on reddit related to Lisp, people raise the following objections:

  • Lisp does not interface with the C-based world easily, unlike scripting languages – this is clearly false, since most Lisp implementations have easy to use FFIs. To bind a C library to Ruby, you have to write C code which glues the library to the Ruby runtime system. With CFFI (which is portable across CL implementations), you just list the function prototypes in your Lisp file and you’re ready to go. You can also pass structs, etc. Factor’s C library interface works the same way.
  • Common Lisp was designed to perform well on Lisp machines only, and makes no concessions to ordinary computers. - this is partially true, but the CL standard did omit some features found on Lisp machines which would be difficult to implement efficiently on conventional hardware. However none of this can change the fact that Common Lisp implementations are an order of magnitude faster than scripting languages.
  • Look at all these parentheses! - of course if you don’t need metaprogramming, macros, and code-as-data, may as well not use Lisp.

There are many other common misconceptions. The “Lisp only supports linked lists” and “Lisp is unsuitable for writing real-world programs” memes seem to have died down in the last few years, but more myths have taken their place. This leads me to believe that the main problem the Lisp community faces to ensure wider adoption (assuming wider adoption is what they want, which is not necessarily the case) is not a technical one, or an internal social problem as some suggest, but rather an education problem.

Most people simply don’t know anything about Lisp, but feel qualified to discuss it and criticize it. Like I said, I’m not a member of the Lisp community (whatever that may be), but when advocating Lisp, Lispers should remember that a lot of things that they take for granted (sane language semantics, C library interface that works, metaprogramming, good performance from a high-level language) are completely foreign to most programmers! There’s a communication gap.

And to all the programmers learning new languages, not just specifically Lisp, please hold off criticism until you know the language and have completed a significant project in it. If you did not get that far, don’t criticize the language, and put it down to lack of time, lack of motivation or personal failing.

I can rag on Java all I want because I know it better than most Java advocates. But if you were first exposed to Lisp 2 weeks ago, then don’t make yet another blog posting about parentheses, even if you work for Google. You’re just wasting bandwidth.