back

by surprisetalk·3y ago·view on hn ↗
My latest iteration uses a bootstrapped compiler written in scrapscript :)

The bootstrapper was written in Elm, because its parsing combinator library is by far the nicest to use.

I wrote a rust bootstrapper in ~2019, but it was much too heavy for my experimentation phase. I think rust would be a good candidate going forward for the bootstrapper going forward though.

I'm open to suggestions!

1 comments
Elm, a nice surprise.

I don't have experience with writing compilers, so I can't suggest anything. I just know that Haskell is promoted as a language suitable for this kind of task. Have you looked at it?

Yes, but I wasn't super happy with it. Rust was a much better option IMO.

I only chose Elm because I was experimenting with some visual debugging stuff, and boy, it's really a joyful experience. The problem with Elm is that it's impossible to write a serious compiler in it hahaha

Do you remember what made the Haskell experience unpleasant?
I can imagine enjoying Haskell in a team setting with existing patterns, but I think its flexibility gives my mind decision fatigue when starting from-scratch.
Do you mean the language in general or the tooling around compilers?