Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dungsaga/511aec74e06405c6f4bfa6903e2bf36b to your computer and use it in GitHub Desktop.
Save dungsaga/511aec74e06405c6f4bfa6903e2bf36b to your computer and use it in GitHub Desktop.
If programming is more than just a means of getting things done for you, then Common Lisp is for you!

Opinionated Common Lisp Resources 2020

If programming is more than just a means of getting things done for you, then Common Lisp is for you!

Table of Contents

What is Common Lisp?

A programming language.

What is so special about it? A part of the problem of explaining Common Lisp to non-lispers is that it is akin to explaining Calculus to a middle schooler - one needs plenty of concepts. Explaining something like python to a C programmer who has never used a higher level language would require explaining, perhaps, first order functions and the concept of objects. Explaining Common Lisp to a python programmer requires explaining macros (and the associated details about read-compile-run time), dynamic scoping, condition system, images, off the top of my head. Each of it can seem like a what?

I don't mean this in a demeaning sense - one can get far by knowing just a few things; but if you are curious about the realm of programming possibilities, then welcome to the world of Common Lisp :)! After all this, if someone still wants to have a read at what is so special about lisp, have a read here.

(Very often, newcomers confuse CLisp with Common Lisp. (GNU) CLisp is just an implementation of Common Lisp. It isn't as good or as maintained as several other implementations, like, say SBCL. See the last section below.)

Lisp for absolute beginners

These are not specifically for Common Lisp, but rather for Scheme and Racket, The things learnt here should be transferable to other languages:

Common Lisp Learning Resources

For beginners:

For the former, be sure to pick up a post-1994 version, since it was in 1994 that Common Lisp gained ANSI standardization.

For people with at least some programming background (1 year?)

This is very opinionated. A more larger list is available at the cookbook itself, the sidebar of r/lisp, the Common Lisp website itself, CLiki, and probably at several other places. Here I wanted to achieve a balance between keeping the page short enough to avoid overwhelming as well as covering just enough to get new programmers onboard.

Libraries

Primarily,

But also:

Quicklisp is a distro-like common lisp package manager - there are "releases" once every month or so. And there's a guarantee that all the packages in a particular release work together.

However, if the one month development cycle is too long, there is the ultralisp that builds every 5 minutes, in that one doesn't have to wait for a month to fix bugs or get the latest libraries. However, there's no "everything builds together" guarantee.

There's a read-worthy discussion discussing the two philosophies here.

Programming Environment

If the reader is okay with Emacs:

Without Emacs:

  • try out slima for Atom - atom-slime is no longer maintained!
  • Alive for VS Code

For vim-users:

If you want a bare bones REPL, here's a three step guide for Ubuntu.

A good fun in using lisps is being comfortable with SLIME, that enables interactive development. I find this akin to going *inside *a building being constructed, with a hammer and several other tools, and then, incrementally modifying or building that building. This video should illustrate the idea.  This provides a larger list of shortcuts, though, the most useful commands I find include C-c C-c, M-. and M-,. This illustrates a wild combination of programming and concerts (yes, musical concerts!), that uses interactive development!

Communities

While asking for help, it's a good practice to first google (or duckduckgo or whatever) your own query to see if it has been asked before.

More Technical Documentation

You don't want to read this! Go back!

Common Lisp is an ANSI standard (standardized in 1994). This is the language. The language has implementations - SBCL, CCL, ABCL, ECL, CLISP, Clasp, Allegro CL, LispWorks, MOCL and may be a few more.

The standard exists in the form of The Common Lisp HyperSpec

  • not very accessible we agree. There is an attempt to make the documentation more "attractive" at The Common Lisp UltraSpec.

Individual implementations also have manuals such as the SBCL User Manual or the CCL Manual or the ECL Manual or err ... you got it!

There's also the Common Lisp Wiki.

I told you you shouldn't read this section! Go back to the previous sections and learn lisp. And then, come here if you want to do something mission critical! There are some very experienced lispers (the creators of these stuff themselves!) out in the community whom you should consult.

Practical Reasons to use Common Lisp

Amidst all this, are there any practical reasons to use Common Lisp? Check this answer on Quora.

This article was originally published by me on my Wordpress blog.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment