We’ve been searching for a memory-safe programming language to replace C++ in Ladybird for a while now. We previously explored Swift, but the C++ interop never quite got there, and platform support outside the Apple ecosystem was limited. Rust is a different story. The ecosystem is far more mature for systems programming, and many of our contributors already know the language. Going forward, we are rewriting parts of Ladybird in Rust.
Porting LibJS
I used Claude Code and Codex for the translation. This was human-directed, not autonomous code generation. I decided what to port, in what order, and what the Rust code should look like. It was hundreds of small prompts, steering the agents where things needed to go. After the initial translation, I ran multiple passes of adversarial review, asking different models to analyze the code for mistakes and bad patterns.
60 Comments
Solumbran@lemmy.world · 92 pts · 173d
"We want rust for safety. That's why we made the code in the most unreliable way to code known to humanity".
Not surprising from the devs that think that not being a fascist is political I guess
Edit : ah apparently the guy is not trying to be an enlightened centrist anymore and is a full-on nazi. Heh, who could have guessed? /s
gravitas_deficiency@sh.itjust.works · 24 pts · 173d
Woah wait what? The “let’s vibecode it” angle is fucking stupid, to be clear, but I was unaware of that user drama. Very interesting.
Solumbran@lemmy.world · 34 pts · 173d
It keeps on coming back and ladybird supporters keep on trying to tone it down because they don't want the project to die. But yeah, the guy seems like a big piece of shit.
KryptonNerd@slrpnk.net · 9 pts · 173d
Got a source for that? I tried searching on DDG but couldn't find anything
Solumbran@lemmy.world · 27 pts · 173d
https://drewdevault.com/2025/09/24/2025-09-24-Cloudflare-and-fascists.html
Here's one, you can find more stuff by searching the name of the dev
hackerwacker@lemmy.ml · 1 pts · 172d
SwooshBakery624@programming.dev · 8 pts · 173d
I will copy my comment here:
However, I completely agree regarding the use of AI, especially in a project such as a browser engine.
EDIT: I accidentally replied to this comment instead of the one with the link to Drew DeVault's blog. My bad.
orc_princess@lemmy.ml · 5 pts · 173d
That is appalling, and I don't mean to diminish the importance of this, but if the claims on fascism stand to scrutiny then it's not relevant, and if the claims don't stand to scrutiny they can be easily refuted.
Edit: and to be clear, I know DHH, I've read his blog and his social media activity, he's clearly a fascist.
UnspecificGravity@piefed.social · 3 pts · 173d
Most of the information that you get about terrible people comes from terrible people because that is who knows them. Should we discount Trump accusations from Epstein because they came from a known pedo? No, pedos are the people that Trump hangs out with because that is what he is.
TomAwezome@lemmy.world · -11 pts · 173d
Given that Drew Devault has pity for pedophiles, the correct choice is to discount anything he says, much like you should discount anything Trump or Epstein claims without further primary sources of evidence from unaffiliated parties
Spectrism@lemmy.dbzer0.com · 6 pts · 173d
This is not at all comparable to Trump/Epstein. Drew was only pitying pedophiles, not actual rapists This may come as a surprise to you, but there is a very clear difference (one is a choice, the other is not).
TomAwezome@lemmy.world · -9 pts · 173d
Nobody should pity pedophiles, you should want them removed from society permanently. If that's controversial, so be it
feddinand@feddit.org · 10 pts · 173d
Then you’ve probably never really thought about what pedophilia actually means. My partner works with pedophiles in a clinical setting and there’s way more people with pedophile tendencies than you’d think (or at least than I thought). Most of them realise it’s a problem early on and seek help, some live in shame for most of their lives and only a tiny percentage actually does something to kids. Obviously, this shouldn’t happen at all (!!) but saying „all pedophiles should be removed from society“ is no solution to anything. Just to be sure: I have no idea what the ladybird-guy said about this topic, nor do I know who he is (or even what Ladybird is. I now know it’s a Browser, but that’s it).
TomAwezome@lemmy.world · 4 pts · 173d
Some people are truly sick and need a lot of help to change how their minds work. I respect your partner and their line of work. Hopefully they all can undergo thorough and intensive rehabilitative care as far away from society as possible until they are fit to be around vulnerable people.
Spectrism@lemmy.dbzer0.com · 9 pts · 173d
With this line of thinking I'd rather remove you from society
TomAwezome@lemmy.world · -6 pts · 173d
You'd agree of course, that pedophiles should be removed from society? Is the idea of shaming pedophiles and pedo apologists some kind of line in the sand that shouldn't be crossed in your eyes?
WalrusDragonOnABike@reddthat.com · 2 pts · 172d
When they don't seem to know what definition the person is using for the word after writing an actual and seem confused why some of the quotes are against sexual abuse of 14 year olds, it's sorta hard to take their claims serious. IF DD's point is just people with the sexual preference deserve pity, then I agree. Just in the same way I think people with problems such as gambling or drug addictions should be pitied - it's not something they've chosen and it negatively effects their quality of life. Otoh, I don't think a gambling addict, for example, should be forgiven if they bankrupt their family and cause their children to grow up in poverty unnecessarily. Otoh, it it's a history of defending child abuse, then agreed there should be some discounting going on (but that seems the opposite of the quotes provided).
Either way, isn't the record for ladybird stuff in the git repo or something like that? Doesn't really matter what the source is that brought attention to it if you have the primary source (but people shouldn't be linking to problematic blogs - either link to the primary source or find/make another user-friendly secondary source).
null@piefed.nullspace.lol · 0 pts · 173d
morto@piefed.social · 51 pts · 173d
We need competition in the browser market, ANY competition!
* ladybird appears *
Well... that was on me, I set the bar too low
toastal@lemmy.ml · 2 pts · 172d
I mean when they adopted MS GitHub & Discord as their only modes of community & contribution, you can know any “open source” project is built on sand
SwooshBakery624@programming.dev · 48 pts · 173d
I am completely disappointed in Ladybird, even though I had some hope for the project until now. I guess all that's left to do is wait for Servo.
racketlauncher831@lemmy.ml · 31 pts · 173d
Your final hope at this point is announcing you will not use LLM to write any part of your program, including tests. Adopting a language which your developers are less familiar is bad enough, and you're writing it with LLM? I'd rather you stick with C++.
bold_omi@lemmy.today · 0 pts · 172d
It uses AI? Right, then I'm boycotting it ad infinitum.
Penta@lemmy.world · 9 pts · 173d
The Lunduke vid about this is going to be lit
darkkite@lemmy.ml · 8 pts · 173d
The requirement from the start was byte-for-byte identical output from both pipelines. The result was about 25,000 lines of Rust, and the entire port took about two weeks. The same work would have taken me multiple months to do by hand. We’ve verified that every AST produced by the Rust parser is identical to the C++ one, and all bytecode generated by the Rust compiler is identical to the C++ compiler’s output. Zero regressions across the board:
Seems like a non-issue.
GraveyardOrbit@lemmy.zip · 4 pts · 173d
darkkite@lemmy.ml · 2 pts · 172d
Why is that? LLM can generate readable code that can be reviewed prior to merging into the main branch. If you work in small pieces reducing risk.
Jakeroxs@sh.itjust.works · -3 pts · 172d
There's no arguing with anti-AI people it's pointless
LiveLM@lemmy.zip · 6 pts · 172d
It's as if everybody told you this the second you announced your move to Swift but aight.
TacoButtPlug@sh.itjust.works · 6 pts · 172d
So confused why they openly admitted to using AI to code it for them
chris14@lemmings.world · 3 pts · 171d
Blisterexe@lemmy.zip · -10 pts · 173d
Actually not a terrible way to use AI. Hopefully the port goes well
Solumbran@lemmy.world · 13 pts · 173d
There will be people defending ladybird no matter what huh
Peer@discuss.tchncs.de · 14 pts · 173d
I read the comment to only refer to the way AI was used.
HubertManne@piefed.social · -4 pts · 173d
I came to say this sounds like a good example of how to use ai. Its going to be used but the big problem is folks who will take the output and say good enough.
Blisterexe@lemmy.zip · -4 pts · 173d
Yeah, using AI to help you rewrite code (which is tedious) in a scenario where there are clear test cases (it either works or it doesn't) is basically the ideal usecase.
gravitas_deficiency@sh.itjust.works · 9 pts · 173d
...no… this is a bad idea. Especially in a browser, given the myriad safety and security concerns in play. This is an objectively bad way to make changes to the project. I can just about guarantee they’re going to introduce some horrid subtle flaws.
Blisterexe@lemmy.zip · 12 pts · 173d
I may be misinformed but the article says
which I took to mean that the new code behaves 100% identically to the old code, like a byte-perfect decompilation. If that's not the case and it's just the same in their suite of tests then I'd agree with you.
Liketearsinrain@lemmy.ml · 10 pts · 173d