you should have gone for the head

2 months ago by cm0002 to c/programmer_humor

bitjunkie 39 points 2 months ago

So bun is going to suck soon?

path: 0 25258980, hotness: undefined, score: 39, children: 11
SwooshBakery624 91 points 2 months ago

Fun fact: After Anthropic rewrote Bun in Rust, Zig's lead developer stated that they used Bun as an example of how not to write Zig code. So, the answer is that is always did.

path: 0 25258980 25259354, hotness: undefined, score: 91, children: 7
red_bull_of_juarez 59 points 2 months ago

Because of the names, your comment sounds utterly ridiculous to someone who has never heard of Bun or Zig.

Source: someone who has never heard of Bun or Zig.

path: 0 25258980 25259354 25260314, hotness: undefined, score: 59, children: 0
mamg22 22 points 2 months ago

So they rewrote poor Zig code into what probably is even poorer Rust code, and from what I've seen, using their AI to do it. Yeah, that sounds like they're getting a fully functional and non-buggy piece of software.

path: 0 25258980 25259354 25262103, hotness: undefined, score: 22, children: 3
Ghoelian 7 points 2 months ago

And they're initially doing it without Rust's memory safety borrow checker iirc, so a big part of the benefit isn't there

path: 0 25258980 25259354 25262103 25266281, hotness: undefined, score: 7, children: 2
Traister101 7 points 2 months ago

Unsafe Rust code doesn't turn off the borrow checker, it basically just allows you to play with pointers and call code that the compiler can't (or can't right now) statically assert is sound. IE if you roll your own Vtable the functions are safe to call, but the compiler can't tell so you have to use unsafe

path: 0 25258980 25259354 25262103 25266281 25267740, hotness: undefined, score: 7, children: 0
mamg22 2 points 2 months ago

Ok this is funny. Like "look bro, we rewrote bun in Rust because it's ✨Safe✨ and all that", and they're not even trying lmao

In all seriousness, part of that issue probably comes from the original code already ignoring the safety features of Zig, and whatever LLM they used to port it just doing the most half-assed thing and doing a literal translation of the code.

The future of software development, ladies and gentlemen

Edit: rust safety

Yes I know unsafe in rust doesn't mean unsafe code, it just that the compiler trusts you to correctly use the interfaces and references since it won't check them inside such blocks

path: 0 25258980 25259354 25262103 25266281 25267691, hotness: undefined, score: 2, children: 0
30p87 2 points 2 months ago

I mean, Bun itself serves a language that should not exist

path: 0 25258980 25259354 25265832, hotness: undefined, score: 2, children: 0
SchwertImStein 1 point 2 months ago

not exactly what he stated, but the code was poor even pre ai

path: 0 25258980 25259354 25340974, hotness: undefined, score: 1, children: 0
Anafabula 32 points 2 months ago path: 0 25258980 25259406, hotness: undefined, score: 32, children: 2
JustJack23 17 points 2 months ago

They haven't had a release after the rewrite, I doubt they will have one soon.

path: 0 25258980 25259406 25260206, hotness: undefined, score: 17, children: 1
Solemarc 12 points 2 months ago

Even better, they used to release twice a month (minimum), it's been 4 months now.

path: 0 25258980 25259406 25260206 25264829, hotness: undefined, score: 12, children: 0
PattyMcB 15 points 2 months ago

Does this mean that half of all the repos on GitHub will soon disappear?

path: 0 25261374, hotness: undefined, score: 15, children: 1
Wirlocke 29 points 2 months ago

path: 0 25261374 25264044, hotness: undefined, score: 29, children: 0
richardisaguy 4 points 2 months ago

AI Users only (1, 4)

path: 0 25265129, hotness: undefined, score: 4, children: 0
onlinepersona 2 points 2 months ago

Has bun even released a version since their Rust rewrite?

path: 0 25306031, hotness: undefined, score: 2, children: 0
programmer_humor
programmer_humor

@programming.dev

login for more options
33644
2565
7638

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

  • Keep content in english
  • No advertisements
  • Posts must be related to programming or programmer topics
    • If the mod doesn't find it funny, you're banned. Ha-ha!... For real: do not use the community for "statements". There are other places for such content. Keep it chill and funny.

go to feed...