toffee-lisp
v0.0.11
Published
ES6 Lisp using persistent hash array mapped tries
Downloads
787
Readme
Toffee Lisp
Features
- Persistent hash array mapped tries
- Multi-arity functions
- loop/recur
- Destructuring
Install
Requires Node.js.
npm i toffee-lisp
Usage
REPL
node repl.js
Run a script
;; script.lisp
(defn yo [name]
(str "what up " name))
(println (yo "dawg"))
$ node toffee.js script.lisp
what up dawg
Use in ES6 module
import {evalString} from "toffee-lisp"
// define a function
evalString('(defn add1 [n] (+ n 1))')
console.log(evalString('(add1 5)'))
// => 6
Test
node test/test.js