I’ve always been curious about programming languages, and LLVM in particular. I decided to build my own using LLVM tools. I built the frontend in C++ and it generates LLVM IR. LLVM handles the rest from there. It doesn’t really have a use case right now, mostly just for fun: https://github.com/kunaljaydesai/slice
Oct 29th, 2023
Still working on the C++ → Rust translation. I’m at parity with the C++ code now except LLVM codegen (with
inkwell) which is next. I haven’t pushed any of it till I get to parity with the C++ code so that’s why the master branch isn’t updated.
Oct 28th, 2023
My next goal with this programming language is to be able to use it in Advent of Code 2023 which should be released in December. I also want to get better at Rust vs. C++, so I’m going to translate the current codebase from C++ to Rust. The LLVM project uses C++ but there’s this library called
inkwell that has “safe” Rust bindings that’ll call out to LLVM code.
Spent some time today translating the code from C++ to Rust. Overall, it’s looking a bit cleaner and I think I got a bit better at writing idiomatic Rust! I’m going to continue working on porting things over from C++ to Rust tomorrow. Hopefully I can finish generating the AST tomorrow so I can start working on the