Better HN
topnewbestaskshowjobs
Log inSign up

celso_

4 karma · joined Jun 15, 2020 (6y ago) · 4 submissions

Submissions

comment 5y ago · link · parent

I’m planning on writing a racket one in the near future, no plans for Python or JS on my side, but you can join the milho train if you want

comment 5y ago · link · parent

Thank you! It's being quite a fun experience for me!

Most of the features are inspired by racket (we've never used a LISP before starting the project, and a friend of mine suggested to use it). Right now we have: - Numbers (rationals) and arithmetic operations - Strings and some basic operations like split and concatenation - Error raising/handling via the raise and call-with-error-handler special forms - Anonymous (via fn) and named (via defn) functions, both single-arity, variadic, and multi-arity - Definitions via the def special form (replaces the whole reference in the variable table) - Local definitions via the let special form - Mutation via the set! special form (gets the reference, replaces its value) - Local state mutation via a combination of let + set! - A simple macro system that only handles basic variable replacing and spreading of lists - cons/car/cdr as it's a LISP after all - Boolean operators and a `if` special form - A simple import system that we're working on right now

There are some examples of functions built with the language inside the `std/` folder, I've created `map`, `filter`, `foldl`, `foldr`, and a mutable list using the functions, and `or`, `and` and `guard` macros using the macro system.

comment 5y ago · link · parent

Milho is a language that I've been working with a friend for a while. The idea is to a be an easy-to-implement LISP with various implementations (we have Haskell, Rust, Go and OCaml for now). Documentation and language specs are still WIP, but we are slowly working on it.

4.

Show HN: The Milho Language(github.com ↗)

7 points · by celso_ · 5y ago · 5 comments