FredrikMeyer / elm-lisp

A Lisp interpreter in Elm

Home Page:https://fredrikmeyer.net/elm-lisp/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Lisp in Elm

This is a Lisp interpreter written in Elm. Test it live on fredrikmeyer.github.io/elm-lisp/.

I try to follow the instructions at Mal.

  • Step 0: REPL
  • Step 1: Read and print
  • Step 2: Eval
  • Step 3: Environments (implemented let instead of let*)
  • Step 4: If fn do (mostly)
  • Step 5: Tail call optimization
  • Step 6: Files, mutation, and evil (files are maybe not necessary!?)
  • Step 7: Quoting
  • Step 8: Macros
  • Step 9: Try

Run in browser

npm start

Build

npm run build

Run tests

npm test

Or

elm-test --watch

for live updates.

TODOs

  • Maybe use CodeMirror to get a better editor. I.e. don't do any HTML in Elm.

About

A Lisp interpreter in Elm

https://fredrikmeyer.net/elm-lisp/


Languages

Language:Elm 95.5%Language:CSS 2.0%Language:TypeScript 1.0%Language:JavaScript 0.9%Language:HTML 0.6%