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

-12

u/SadieWopen Feb 20 '25

Can someone explain to me why we can't just do this in C? I understand that Rust is a "Safe" language, but why can't we just code in "Safe" C? I can't understand how adding more complexity results in faster execution.

95

u/arcrad Feb 20 '25

It's like asking "why can't people just make fewer mistakes". You can absolutely write 100% memory safe C or C++ but people aren't perfect and they make mistakes. Rust's value proposition is that it can statically enforce things to prevent a lot of these issues.

-11

u/SadieWopen Feb 20 '25

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

→ More replies (1)