logoalt Hacker News

Bun is being ported from Zig to Rust

454 pointsby SergeAxtoday at 1:08 AM324 commentsview on HN

Comments

larpatoday at 1:34 AM

"Claude, migrate bun to Rust, make no mistakes"

forrestthewoodstoday at 3:15 AM

I hope they ship and use this. It’ll be a super interesting case study in a few years.

show 1 reply
gib444today at 5:24 AM

> Read this whole document before writing any code.

Hm does that actually work?

Edit: in a way that can be verified, and not the AI tool saying it did

altuntoday at 7:12 AM

I guess it's like Trump saying, "I'll take Greenland too..."

Capricorn2481today at 3:08 AM

April 26th - Bun announces they used AI to fork Zig so they could make an optimization for a 4x improvement

April 27th - Zig contributor mlugg clarifies why the specific optimizations Bun did were ill advised and wouldn't have been accepted in Zig, regardless of AI use [1]

May 4 - Bun is looking into Rust as an alternative.

This, to me, seems like total whiplash. Has anyone at Bun made a statement on why they're making such dramatic changes? It seems like the lesson to internalize from mlugg is not "switch to Rust"

[1] https://lobste.rs/s/ifcyr1/contributor_poker_zig_s_ai_ban#c_...

show 2 replies
booleandilemmatoday at 2:13 AM

Interesting. When I thought of Zig, I thought of Bun. In my mind it was the flagship application for that language. Is there another? I wonder how the Zig team feels about this. To me it seems like Rust has definitively won now.

show 2 replies
iamgopaltoday at 4:07 AM

the days are not far when golang will be ported to rust.

show 1 reply
sergiotapiatoday at 1:58 AM

>*No `tokio`, `rayon`, `hyper`, `async-trait`, `futures`.* No `std::fs`,

I'm not a rust dev but even I kind of notice that tokio is kind of shunned in most projects. Why is that? Is it just bad or what?

show 10 replies
GianFabientoday at 4:39 AM

Here we go again ...

Company A buys company B. A's management decrees the henceforth B's aqcuihired team must comply with company A's standards.

Second system effect kicks in. Bugs multiply.

Half of original company B devs leave.

I'm investigating whether future projects should revert to using Deno.

ConanRustoday at 1:35 AM

instead of writing it once in C++

markovmodeltoday at 5:48 AM

what a win

0x142857today at 1:34 AM

you can use both zig and rust in a single project, duh

show 1 reply
matrix12today at 3:36 AM

it will make it more portable.

lacymorrowtoday at 7:07 AM

[dead]

Amber-chentoday at 2:51 AM

[dead]

y534y5today at 2:53 AM

[dead]

hakrgrltoday at 3:25 AM

People are asking why they would switch from zig to rust. I wonder the opposite: why would anyone would use zig over rust?

show 1 reply
nothinkjustaitoday at 2:02 AM

Makes sense on merit. There really isn’t room for Zig when Rust exists, is more ergonomic, and also safe.

Entambitoday at 2:19 AM

hahaha eat your heart out "don't port it to rust" gang

show 1 reply
AbuAssartoday at 4:09 AM

I fully support this decision