Author: Emma Smith
Created at: 2025-11-19 07:32
Number: 132
Clean content: Dima Tisnek: Which is why I’m calling for the equivalent of PEP-7 for Rust use in CPython. This is definitely something I hope to work on with folks. We will need a standard style for Rust in CPython, but I also think that might depend as we adopt Rust and expand the current proof of concept. Regardless it probably should be it’s own PEP, in my mind drafted and published after this one is approved. Dima Tisnek: RustBelt has proven something about Rust, but not about Rust use in CPython That’s certainly true, but in projects that have adopted Rust for a while, we see significant decreases in memory safety bugs. Here’s an excerpt from a blog about Rust adoption in Android: We adopted Rust for its security and are seeing a 1000x reduction in memory safety vulnerability density compared to Android’s C and C++ code . But the biggest surprise was Rust’s impact on software delivery. With Rust changes having a 4x lower rollback rate and spending 25% less time in code review Our historical data for C and C++ shows a density of closer to 1,000 memory safety vulnerabilities per MLOC. Our Rust code is currently tracking at a density orders of magnitude lower: a more than 1000x reduction. From Google Online Security Blog: Rust in Android: move fast and fix things I agree with you that it is important to highlight that Rust can increase developer velocity as well as provide memory safety. I think this is something we will highlight more in the PEP draft and is something a few people have mentioned. Here’s another excerpt from the above blog related to that: For medium and large changes, the rollback rate of Rust changes in Android is ~4x lower than C++. Rust changes currently spend about 25% less time in code review compared to C++. These are definitely things we will be focusing on more in the PEP text itself.
