A tree-walking Lisp interpreter written in Gleam!
It features:
- Ints with
+,-,*, and/. - Bools with
not,and, andor. - Comparison with
=. - Lists with
empty,cons,car,cdr. - Closures with
lambda. - Global variables with
define. - Local variables with
let. - Flow control with
if.
import glisp
pub fn main() {
glisp.eval("(+ 1 2 3)") //=> "6"
}I wrote this on a transatlantic flight on a day that involved no sleep so expect bugs and other curiosities.