13 Juillet

Anthropic's Bun rewrite is marketing and the Zig creator isn't having it

Anthropic acquired Bun, the TypeScript runtime that was one of the largest codebases written in Zig. Then Bun’s founder Jarred Sumner used AI agents to rewrite the entire thing from Zig to Rust in a massive agentic experiment. The rewrite was merged to mainline two months ago. The explanation came out this week.

The Register ran headlines about the “speed of AI.” Anthropic got to tell investors that their models can autonomously rewrite a production runtime. Great timing for a company that raised $132 billion and is approaching a trillion-dollar IPO.

Zig creator Andrew Kelley published a response. It was blunt. Some called it a meltdown. A blog post by Ray Myers, a former coding agent startup CTO who worked with Anthropic’s models, cheered it on and laid out the case in devastating detail. It hit the front page of Hacker News and collected 639 points and 300 comments in hours.

The core accusation is simple. The rewrite was not primarily an engineering decision. It was a marketing event.

Here is the thing. Nobody actually involved wants Bun to stay in Zig. The migration process itself is genuinely interesting. File-by-file porting to unsafe Rust to minimize risk, then redesign later. That is a reasonable strategy explained well.

The problem is everything around it.

The rewrite rationale is fluff

A real engineering decision explains motivation, options considered, and tradeoffs. Bun’s writeup gave motivation. It waved at options. It skipped cons entirely. The “Bun is better in Rust” section listed only upsides. No mention of build time impact, which matters enormously for a project that previously forked its compiler to improve compilation speed.

The motivation was memory bugs. Four fix commits per week. Painful. The obvious question: did they try a style guide? Another flagship Zig codebase, TigerBeetle, has zero memory bug problems. They use TigerStyle, an engineering philosophy with strict allocation rules. All memory statically allocated at startup. No dynamic allocation after initialization. This eliminates use-after-free by construction.

Bun’s writeup mentions style guides, pays lip service to them, then dismisses them. The objection is that style guides are hard to enforce. But Bun already claims to have solved enforcement through agentic code review. They conducted an agentic review of their entire rewritten codebase against stringent guidelines. So enforcement is solved when it serves the rewrite narrative, but unsolvable when it would have saved the original Zig codebase. Pick one.

The irony

Every decision in this story confirms that AI is not enough.

They wrapped LLMs in agent harnesses because AI is not enough. They chose Rust’s borrow checker because AI is not enough. They emphasized code structure should be familiar to maintainers because AI is not enough. They worried about pointer wrapper ergonomics because AI is not enough.

Meanwhile Anthropic is telling the world that coding is going away. That software engineering is next. That most human labor follows.

The same AI that supposedly can replace all programmers could not catch a use-after-free. That is why they needed Rust.

Why this matters

Anthropic needs the “AI replaces engineering” story to justify their valuation. They cannot show profitability. They are selling hypothetical future impact. Every C-suite, world leader, and retirement fund manager who believes coding is ending is another dollar in the IPO.

People will make architecture, product, and staffing decisions based on this narrative. Many will be driven by fear. Layoffs, rapture-style warnings about being left behind, doom trolling.

The Bun rewrite is being used as evidence. Look, AI rewrote a production runtime! Except it did not. Humans directed agents through a file-by-file port to a language whose compiler catches the bugs the agents could not. The agents were tools in a human-led migration. That is impressive. It is also not the story Anthropic is selling.

Andrew Kelley calling it out matters because the Bun situation will be cited as a data point in every Zig versus Rust discussion for years. If Anthropic’s megaphone controls the narrative, the technical reality gets buried under IPO marketing.

Myers puts it bluntly: we are here to build things people want and build them well. In the AI bubble, we are pressured to build things nobody wants, poorly. Pop the bubble.

Sources: Ray Myers’ analysis, Hacker News discussion, Bun’s PORTING.md, Andrew Kelley’s response

Mots-cles

anthropic bun zig rust ai coding ipo software engineering