Closed
Description
openedon Feb 4, 2021
I tried this code (playground):
unsafe fn f() {
None.unwrap_or(String::new().as_mut_vec());
}
fn g() {
None.unwrap_or(unsafe { String::new().as_mut_vec() });
}
I expected to see this happen: Clippy warns on both f
and g
.
Instead, this happened: Clippy only warns on f
.
Meta
cargo clippy -V
: 0.1.51 (2021-02-03 e708cbd)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment