#[must_use]
fires when generic type is unit type
#141802
Labels
C-discussion
Category: Discussion or questions that doesn't represent real issues.
L-unused_must_use
Lint: unused_must_use
Uh oh!
There was an error while loading. Please reload this page.
I tried this code:
I expected to see this happen: no warnings
Instead, this happened: warning from unused
()
fromresult.unwrap_infallible()
:warning: unused return value of
UnwrapInfallible::unwrap_infalliblethat must be used
Meta
rustc --version --verbose
:It's also in latest nightly:
2025-5-29
Playground
The text was updated successfully, but these errors were encountered: