First really big Rust project: a compiler

92 points bindernews

I wrote a compiler for Mindustry's logic language in Rust, it's called Minblur.

You can try it out in your browser here.

Feedback is welcome and appreciated.

Features

  • Labels - so you never have to manually edit a jump location again
  • Constants - compile-time text replacements for keeping code clean and readable
  • Macros - Constants but on steroids
  • The m! macro - \``m! i += 1; jump(loop_start, i < 20)`
  • Easily convert existing code to use labels instead of numbered jumps!
  • Comments