Roc’s compiler is being rewritten in Zig primarily due to significantly faster compile times, which have been a major pain point in Rust.
Zig’s allocator-based memory management, better tooling for static binaries, and built-in support for optimization techniques (like struct-of-arrays and bit-packing) align better with Roc’s needs.
@cryptocode I’m quite surprised about the claim of slow compile for Rust code **specifically** written to be fast to compile (like using
dyn
instead ofimpl
). I would love to read more apout what makes Rust intrically slow to compile, even if you are ready to write code in non-idiomatic way.Dunno, I was just summarizing and linking the article. What is not mentioned in the article is Zig’s upcoming incremental compilation which is bonkers fast. Either way I’ll follow this effort with great interest.
@cryptocode It was not in direct response to what you wrote, I read the whole motivation post. Something strange on internet, I know ;) It was quite interesting btw.
Yep, it’s a good one and one to follow :)