2.2 KiB
Common Lisp
Common Lisp is a Lisp dialect, created as a successor of MIT's Maclisp.
It also one of the most efficient (in terms of execution speed) Lisps, almost archiving the performance of an equivalent C program when using a compiler and type hints.
Unlike other Lisps, Common Lisp is gradually typed: by default its type system is dynamic, but it allows to specify the explicit type for a binding, which then a compiler can use for compile-time type checking and for producing better machine code.
It also allows for OOP with the included CLOS (Common Lisp Object System).
Notably Common Lisp also has an interactive environment, SLIME (The Superior Lisp Interaction Mode for Emacs) which allows REPL-driven development and live program debugging. Unfortunately, it seems to be almost vendor-locked into Emacs.
Implementations
- SBCL (Steel Bank Common Lisp): a JIT compiler, seems to be the most popular implementation; public domain.
- CLISP: bytecode interpreter, last release was in 2010 but it is still in active development.
- GCL (GNU Common Lisp): GNU's Common Lisp compiler, based in Kyoto Common Lisp (KCL).
- ECL (Embeddable Common Lisp): compiler, also derived from KCL.
- CCL (Closure Common Lisp).
- KCL (Kyoto Common Lisp): Historical, one of the first compilers made. Made in Kyoto, Japan--hence the name.
- LispWorks: propietary, includes an IDE.
- ...
Examples
(princ "Hello, World!")
TODO
Resources
- Common Lisp HyperSpec: HTML rendition of the Common Lisp ANSI standard, can be found here: https://www.lispworks.com/documentation/HyperSpec/Front/ with some better looking versions here: https://novaspec.org/cl/ and https://cl-community-spec.github.io/pages/index.html.
- CLiki: a Common Lisp Wiki.
- https://lisp-lang.org/: kind of semi-official webpage for Common Lisp.
- The Common Lisp Cookbook