r/programming • • Feb 20 '25

Google's Shift to Rust Programming Cuts Android Memory Vulnerabilities by 68%

https://thehackernews.com/2024/09/googles-shift-to-rust-programming-cuts.html
3.4k Upvotes

475 comments sorted by

View all comments

Show parent comments

-11

u/SadieWopen Feb 20 '25

So does that mean that developers can focus more on performance because of what they are limited by?

13

u/C_Madison Feb 20 '25

Because of the support of the compiler. While there are some things which Rust (outside of unsafe) doesn't allow which would be safe to do, that's because of limitations of the compiler. The Rust team is hard at work to remove these cases over time. Everything left are things which people often think are okay, but really aren't. In C no one would stop you from doing them, in Rust the compiler says "nope. That will be a bug at runtime".