Lightning Jar - Web Studio Lightning Jar Wordmark
Skip to main content
Reading List

Rewriting Bun in Rust

Jarred Sumner
Bun 2026-07-08

Summary:

Jarred Sumner recounts rewriting the entire Bun runtime, roughly 535,000 lines of Zig, into Rust in 11 days using Claude Code with adversarial review loops, a job he estimates would have taken a team a year by hand. The port was mechanical and test-anchored: all 1,448 Zig files became Rust files with zero tests skipped, 6,502 commits landed at a peak of about 1,300 lines per minute, and the result fixed 128 open bugs while introducing 19 regressions that were all subsequently fixed. The payoff is concrete: a roughly 20% smaller binary, 2 to 5% better performance, and multi-gigabyte memory leaks reduced to megabytes. His thesis is the quotable part: one engineer can do a lot more today than a year ago.

Excerpt:

"Jarred Sumner on porting all of Bun from Zig to Rust in 11 days with Claude: 6,502 commits, 128 bugs fixed, and a smaller, faster, memory-safe runtime."
#Bun#Rust#AI#Developer Tools
Read Full Source