Closed ralpha closed 4 years ago
I'm not qualified to have an opinion on this but I remember there being an article somewhere that asked people not to use a global #![forbid(unsafe_code)]
because it made it hard for the Rust developers to mark things as unsafe in the standard library (because it turns any unsafe code into a breaking change). I suggest this be taken into consideration, given how many crates use cfg-if
.
This crate doesn't use any unsafe code and it's highly unlikely to ever do so, but it's not in the contract of this crate that it will never use unsafe code so I'm not going to implement this.
cfg-if
does not seem to use unsafe code, which is very good :)To prevent this from ever happening, add following line to the top:
of https://github.com/alexcrichton/cfg-if/blob/master/src/lib.rs
This will make the package green in https://github.com/rust-secure-code/cargo-geiger