4 ms·
You can use #![deny(unsafe_code)] in your own code. If you're hoping to enforce across all called functions, it's likely to be unworkable since a lot of stdlib
by technion 3y ago
You can use #![deny(unsafe_code)] in your own code.
If you're hoping to enforce across all called functions, it's likely to be unworkable since a lot of stdlib ends up calling unsafe code.
- pitaj 3y agoOr even stronger #![forbid(unsafe_code)] Then it can't be `#[allow()]`ed. There's also things like `cargo gieger` that will tell you how much unsafe code your dependencies have.
- junon 3y agoTIL forbid(), thanks!
- giovannibonetti 3y agoI think you meant `cargo geiger`