Open
Description
Code:
pub fn f() {
let v = &mut &mut Vec::<()>::new();
debug_assert!(v.is_empty()); //~ ERROR do not call a function with mutable arguments inside of `debug_assert!`
}
Error:
error: do not call a function with mutable arguments inside of `debug_assert!`
--> rust/src/lib.rs:17:19
|
17 | debug_assert!(v.is_empty());
| ^^^^^^^^^^^^
|
= note: `#[deny(clippy::debug_assert_with_mut_call)]` on by default
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#debug_assert_with_mut_call