All Projects → danprince → Ljsp

danprince / Ljsp

Lisp in your language.

Programming Languages

javascript
184084 projects - #8 most used programming language
lisp
113 projects

ljsp

A toy Lisp implemented using arrays and functions in Javascript. If you're wondering why such an abomination exists, then go check out the blog post that is responsible for its inception.

Examples

["print", "Hello, World!"]

["defn", "greeting", ["name"],
  ["print", "Hello", "name"]]

["greeting", "Dan"]

["=", 5, 5]

["+", 10, 20]

["and", true, true]

["or", true, false]

For more involved examples, take a look in the examples/ directory. To run an example, use bin/run-example example-name.json.

REPL

To use the REPL, clone the repository and run npm install. This will install the dependencies needed for running the REPL (chalk and readline).

Then running ./bin/repl will start it up. See how it is used in the Asciicast below.

asciicast

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].