How many percent of all errors are memory safety errors? Why did Google choose C/C++ for Fuchsia after evaluating also Rust? How come, Actix announced a new version with memory leaks fixed?
> How many percent of all errors are memory safety errors?
They did not release those numbers.
> Why did Google choose C/C++ for Fuchsia after evaluating also Rust?
A couple of things here:
* We don't actually know if they did evaluate Rust for the kernel or not.
* At the time they would have been making that evaluation, Rust was one year past 1.0, and was significantly less mature than it is now.
* They had a bunch of people who had experience with existing kernels that were in C and C++, and in fact, based Zircon on one of them: LK.
All of these are good reasons to pick what they picked. However, there's one more thing here, and that's that Fuchsia is a microkernel, and so the kernel is a lot smaller than in other OSes. Rust is used for a bunch of components that would be in the kernel if Fuchsia was a monolithic kernel.
> How come, Actix announced a new version with memory leaks fixed?
Well, first of all, memory leaks aren't a memory safety issue, so this would be irrelevant. However, Actix had actual memory safety issues as well, and did fix those. This happened because the author used a lot of unsafe that they didn't need to. This is pretty straightforward though; it was easy to find those issues because of the way that Rust works, and then they were fixed. That's kind of the point!
>> Rust is an overwhelmingly better language than Java or Go
100% agreed
>> and the world would be a better place if Rust were to displace them.
Rust needs a standard lib like Go or ecosystem like Java. Production stuff needs to be stable. Especially Go gets this right.
Rust with a standard lib like Go could rule the business apps world. But Rust doesn't even include an async runtime. It's not a problem, if Rust wants to stay in the niche where it is. Also, Rust advocates should not wonder why the adoption in the general purpose web space is far below its potential.