Pre-feature request: suppress unused variable warning for unit-type arguments
Rust Internals [Unofficial]
March 11, 2026
I've run into a related issue with trait default implementations. I don't want to rename the parameter because it shows up in docs as-is. So I end up with let _ = unused_arg; in the body of the default impl (that doesn't use/need the argument). I agree that a special case on the lint isn't very nice though, so I just kind of live with the in-body "suppression".
Discussion in the ATmosphere