1. 16
  1. 2

    I have been wanting to seriously learn a lisp. My current main languages are Erlang and Elixir so LFE would probably make the most sense, but I’m not too sure how well maintained it is at this point. I have also had people tell me that Racket is too academic, though I am not entirely sure what that is meant to mean (I assume that it is more a tool for teaching/learning and not something people build “real” software in?).

    Would anyone care to breakdown, or point me to an article that does, the differences between some different lisps?

    1. 3

      I’d like to hear more about LFE.

      As for the other lisps; Common Lisp(CL) a standard and has a variety of implementations (paid&free). It is a mature large language with lots of functionality and libraries. It has an object system CLOS and a macro system.

      Schemes differ from CL in that they have a single namespace for functions and variables, so you can’t have a variable and function with the same name. Schemes have hygienic macros, which is a way of dealing with variable capture that differs from CL. There are a variety of implementations for both general purpose and embedded contexts. (LFE is a SCHEME on the BEAM)

      Racket is a ecosystem of tools that supports creation and interoperation of multiple languages (including scheme standards). Racket has

      • hygienic macros, but has extended them to provide better facilities for errors.
      • an object system similar to java, but it also includes an implementation of CLOS
      • tools for making languages!

      A better article about the Racket value proposition: https://beautifulracket.com/appendix/why-lop-why-racket.html

      You can find similar for other lisps too - they all have their strengths :)

      1. 3

        LFE is a multi-value-name lisp (lisp-2), not a Scheme.

      2. 1

        If you’re interested in broadening your horizons and getting a taste of lisp, LFE would be the easiest way to do it; my understanding is that LFE retains Erlang semantics while introducing lisp syntax, so hypothetically the differences between LFE and Erlang would be exactly what is needed in order to lispify it, which would hopefully be enlightening. Finally, learning a new runtime is often more difficult than learning a new language, so you could save a lot of unnecessary headache there.

        On the other hand, unfortunately LFE is a lisp-2, which makes it poorly-suited for programming with higher-order functions. It also has a very small community, so you won’t find very much community code to see what passes as idiomatic. You’d find a lot better learning materials for Racket (arguably theirs are better than any other language, but I wouldn’t say it’s “too academic”; that’s nonsense), and you’d have access to a lot more 3rd-party libraries with Clojure, while learning Emacs Lisp would offer a lot more opportunities for day-to-day experimentation that’s practical without having to find a way to introduce it at work or something.

        It depends what you’re looking for, I guess.

        1. 2

          On the other hand, unfortunately LFE is a lisp-2, which makes it poorly-suited for programming with higher-order functions.

          Err, what?

          Sure, there are different things you have to do, but “poorly-suited”? Harsh.

          1. 1

            Well, I guess that’s somewhat debatable, but at least it’s poorly-suited to learn how to fluently work with higher-order functions.

            If you’ve become accustomed to it from another language then you can do it in a lisp-2, but odds are not good that you’d pick it up just from leaning a lisp-2.