Original title: An update on Bun’s experimental migration from Zig to Rust: The Rust rewrite now passes 99.8% of Bun’s pre-existing Linux x64 glibc test suite.
Article
Bun’s team announced an experimental migration from Zig to Rust, with a branch reaching about 99.8% pass rate on the existing Linux x64 glibc test suite and roughly 960,000 to 1,000,000 lines translated. The update confirms a functional prototype rather than a final product, with maintainers acknowledging remaining work on finishing platforms, reducing unsafe blocks, and making the code idiomatic and manageable. Discussion in the thread frames this as one of the fastest large-scale rewrites ever attempted and attributes speed to prompt-based coding and access to large test infrastructure. Commenters note Bun had previously chosen Zig to control performance and compiler behavior but now appears to prioritize Rust’s stronger memory-safety guarantees after recurring crash and bug concerns. Several participants distinguish feasibility from quality, saying passing tests is only the first gate and that runtime code carries unusually high maintenance and correctness risk. Others observe that the exercise demonstrates a new development economy where model capacity and token budgets can reshape engineering timelines across languages and large codebases. Concerns are raised about hidden costs beyond compilation metrics, including long-term staffing, review practices, and confidence in low-level behavior that tests may not fully capture. The thread also surfaces broader industry-level uncertainty over whether this is an isolated experiment or a signal of a larger shift toward AI-first software translation for foundational infrastructure.
The comments are sharply divided between technical optimism and systemic caution. Supporters admire the pace, with one view that Rust may reduce Bun’s stability pain compared with Zig, and another that the result is a meaningful proof that large runtime migrations can be practical with comprehensive tests and AI assistance. Critics call it dangerous mismanagement for a core runtime, arguing that a six-day migration by one developer creates a codebase many team members cannot deeply understand or safely evolve. Multiple commenters expect short-term value but warn about review bottlenecks, unsafe code, and whether tests can capture edge-case regressions like crashes, deadlocks, and leaks. Some compare the episode to past language-rewrite cycles and suggest this is less about pure engineering than about governance, maintainability, and trust. There is recurring anxiety about AI replacing expertise, while others frame it as a major productivity unlock that could force firms and governments to compete on compute and model access. A secondary thread examines whether the move hurts Zig’s momentum, with opinions split between inevitable decline and limited real ecosystem impact. Broader reflections include speculation about job impact, language specialization, and whether AI-generated code will remain understandable enough for long-term stewardship.