How I developed a faster Ruby interpreter (2022)
developers.redhat.com
developers.redhat.com
Curious. Why is that?
From my experience once you learn Rust, it is very easy to build things and being confident that if it compiles it works, I think C also scares a lot of developers and it's harder to collaborate, because each code review must be carefully review by having a mental model of the entire app, while in Rust obviously that's the job of the compiler.
I think those header files festooned with ifdef's are a nightmare, and it's the wrong choice, a type of premature optimization.
That can lead to a cleaner implementation without conditional compilation (or with conditional compilation restricted to picking the right files).
What other method(s) were you thinking of?
runtime conditional configuration
anything Rust can do, C can do, C can even implement Rust. I'm not saying that you shouldn't prefer Rust, I'm sure it has nice features, i was just trying to clarify confusion about what C "requires" you to do. People use a lot of define blocks, but I don't. It's a throwback to wanting to minimize code size at compile time from back when that was important.
Oh and the borrow checker is good too.
https://shopify.engineering/porting-yjit-ruby-compiler-to-ru...