Live data from Hacker News

Claude Code uses Bun written in Rust now

simonwillison.net

201–210 of 920 posts

Re: Claude Code uses Bun written in Rust now

#201
post #12
post #10

Earlier quoted context omitted.

I am impartial on the matter, but I think one of the reasons Bun became a thing in the first place was because of Zig attracted a small but very active developer community. Switching from Zig to Rust effectively alienates that community.

I think the Zig people are really just worried that maybe Zig itself is a DOA language before it has even reached 1.0 because it doesn't offer enough over C for any serious use and their flagship project has now abandoned it.

Zig is a DOA language for other reasons though. The reason why Rust enthusiasts act so morally superior is because they are:

> Rob Pike, an unsafe guy, may insist that a small language and garbage collection are enough. But the typesafe visionary Grzegorz Wielbodłąński understands the deeper truth: every invalid state permitted by a compiler is a tiny act of civilizational sabotage.

https://x.com/typememetics/status/2078572052680790237

There is no sense pretending anymore that languages with as many gotchas as C and Zig are "simple". Quite simply, they are not. The complexities lie in what's left unspoken, unaddressed, and of course undefined; failure to comprehend these completely can be catastrophic. Rust is so thoroughly and obviously the correct thing that using anything less correct should be taken as a sign of engineering incompetence.

Re: Claude Code uses Bun written in Rust now

#202
post #157

Earlier quoted context omitted.

Seems to be working just fine though? And like, this is just the beginning of the port. They did a mechanical port basically line by line, next step is to make it idiomatic rust. I thought by now people would’ve learned to stop betting against this rewrite.

> Seems to be working just fine though? As with all transpile ports, the true test will be how well it can be extended and maintained over time. Historically working with the output of a transpile is not pleasant and requires heavy rework to get it to the point where you can be comfortable enough to extend it. The existing community is now either going to need to learn Rust or new Rust developers are going to have to…

historically we didn’t have LLMs which don’t mind “unpleasant[ness]” and “heavy rework”.

This is I think a preview of the future of software development. LLMs are having the same effect as compilers, frameworks, etc - they are making new kinds of software development feasible which were not previously so.

Re: Claude Code uses Bun written in Rust now

#203
post #199

Earlier quoted context omitted.

How do you know it's vibe coded slop? Have you seen the source code?

> How do you know it's vibe coded slop? Have you seen the source code? I believe you've just made your opponent's point for them.

Have I? I believe I've merely chased them around their moving goalposts. When it's closed source, that's nefarious because "they're not sharing" and that's against the whole spirit of open source. When it's dogfooding with a reduced audience, it's "shoving vibe coded slop on people" (this information gleaned through magical knowledge). When that unfounded assertion is called, lo and behold: It's closed source, so bad bad bad! It's called a logical fallacy for a reason.

But more to your point: Do you believe in "guilty until proven innocent"? Do you believe that they're doing bad things with the bun code, and you can't be convinced otherwise in your judgment of them until they release the code?

Re: Claude Code uses Bun written in Rust now

#204
post #159
post #74

Earlier quoted context omitted.

> But I'm beginning to wonder whether that will even matter in a few months. At that point, even Bun itself doesn't matter. All intermediate tools don't matter if LLMs can reliably write something large. The problem is that LLM is not quite there yet. The rewrite was only possible because they mostly stick to 1-to-1 translation resulting in non-idiomatic Rust code. So, what from there? I don't think they can really b…

Isn't it just: "while true {refactorIdiomatically(); fixErrors()}"

/goal fix all bugs

Re: Claude Code uses Bun written in Rust now

#205
post #194
post #93

Earlier quoted context omitted.

I agree, it's unfortunate the headlines seem to have become 'rewritten in Rust' (not a bad thing) and not 'vibecoded in a week without review' (a bad thing).

"Vibecoded" is not an accurate description of what actually happened. LLMs are extremely good at porting code from one language to another while preserving semantics. Which is why how everything turned out so well was not very surprising.

"Preserving semantics" by casting pointers to aliasing refs in Rust, ignoring lints and errors in the process.

Can't help laughing at this point.

Re: Claude Code uses Bun written in Rust now

#207
post #93

Earlier quoted context omitted.

I agree, it's unfortunate the headlines seem to have become 'rewritten in Rust' (not a bad thing) and not 'vibecoded in a week without review' (a bad thing).

Surely a lot of review has happened in the last two months?

Reviewing is meaningless while they are still keeping the 10433 (sorry it has become 10503 since last week) unsafe blocks, most unsound and none encapsulated.

Any review would get to the simple conclusion that this should not be released before all the obvious bads are sorted out.

Re: Claude Code uses Bun written in Rust now

#208

It's a transpile. And not even a good one. The generated code is far from idiomatic rust. Some may consider it an abomination.

Seems to be working just fine though? And like, this is just the beginning of the port. They did a mechanical port basically line by line, next step is to make it idiomatic rust. I thought by now people would’ve learned to stop betting against this rewrite.

> next step is to make it idiomatic rust

You can tell what will happen when they release it before sorting out all the new bugs introduced by the not-exactly-line-by-line port.

Re: Claude Code uses Bun written in Rust now

#210
post #100
post #18

Earlier quoted context omitted.

It’s made absolutely no negative difference, as we’ve seen in the real world in the last 60 days since the merge. I feel weird having to defend reality; reality being that it was merged nearly 2 months ago and tons of people have had their pitchforks out without a shred of actual evidence that this made bun worse in any measurable way. But they still insist it was a mistake. I’ve never met Jared or the bun team but I…

> who cares what language a JS toolset is written in? Anthropic, apparently, not the least because they blanket-closed all issues submitted before the rewrite. If the language were irrelevant, it shouldn’t matter for the existing unfixed issues.

[deleted]
Post reply on HN