It's only 4% unsafe and most of it is single-line pointers that came from C++

> At the time of writing, about 4% of Bun's Rust code sits inside an unsafe block (~13,000 unsafe keywords across ~27,000 lines / ~780,000 lines), and 78% of those blocks are a single line — a pointer that came from C++, or one call into a C library.

I don't know much about Rust but I imagine this is safer than 100% 'unsafe' code in Zig or C++.

That’s a lot of unsafe. I worked in a project with 50k lines of rust. 9 lines were unsafe. Turned out one of those was a hairy bug. Now it’s 8 lines.

4% of 100k is 4k. 4k lines of unsafe rust is more likely to be unmanageable compared to 4k lines of zig or c dependency on a 100k line rust codebase.

Not sure if they have 100k or a million lines of code

I'm honestly surprised, almost disappointed, that Claude couldn't reduce this 4% to way less.