articles/lisp.md: update
This commit is contained in:
parent
a3e26984e7
commit
287d2d5557
1 changed files with 4 additions and 3 deletions
|
@ -1,7 +1,7 @@
|
|||
# Lisp
|
||||
Lisp (originally LISP for **Lis**t **P**rocessing) is a family of [programming languages](programming_language.md) that share common features
|
||||
such as the S-Expression syntax, powerful metaprogramming capabilities with macros adding extensibility, the use of lists
|
||||
as the principal data structure, first-class functions (lambdas), garbage collection and recursion.
|
||||
as the principal [data structure](data_structure.md), first-class functions (lambdas), garbage collection and recursion.
|
||||
|
||||
Lisp was created in 1958 by John McCarthy, making Lisp on of the oldest languages used today, second to Fortran.
|
||||
Originally Lisp didn't use the now ubiquitous S-Expression syntax but M-Expressions (as used in the Lisp 1.5 manual), however S-Expressions turned
|
||||
|
@ -9,7 +9,7 @@ out to be more popular and Lisps began using it.
|
|||
|
||||
Unlike other languages at the time and also modern languages, Lisp is homoiconic, that is, Lisp source code is data that can be manipulated
|
||||
by the program itself. This gives Lisp powerful metaprogramming capabilities through the use of macros which modify the program data at compile
|
||||
time. Therefore, Lisp source code directly represents the program as a tree without extra superfluous syntax (as in "mainstream" programming languages).
|
||||
time. Therefore, Lisp source code directly represents the program as a tree without extra superfluous syntax (as in "mainstream" [programming languages](programming_language.md)).
|
||||
|
||||
A PDF of the original Lisp 1.5 manual can be found here: <https://www.lispmachine.net/books/LISP_1.5_Programmers_Manual.pdf>. Head to page 13 for
|
||||
enlightenment.
|
||||
|
@ -75,12 +75,13 @@ you're seeing the source encoded in a tree, directly by using S-Expressions. But
|
|||
;; (*) 16
|
||||
;; / \
|
||||
;; 20 2
|
||||
;; Or simply equivalent to this Lisp expression:
|
||||
(* (/ (+ (* 20 2) 16) 30) 5)
|
||||
```
|
||||
|
||||
## Lisp languages in use
|
||||
- [Scheme](scheme.md): created by the hackers Guy Steele and Gerald Sussman in 1975 at the MIT.
|
||||
- [Common Lisp](common_lisp.md): Big for Lisp standards (still better and smaller than "modern" languages), is also the most used Lisp today.
|
||||
The main implementation is SBCL, a public domain JIT compiler.
|
||||
- Clojure: based in the [JVM](jvm.md) (Java Virtual Machine), does not have `cons`, `car` or `cdr`.
|
||||
- ...
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue