]> git.proxmox.com Git - rustc.git/blame - src/tools/clippy/src/docs/double_must_use.txt
New upstream version 1.66.0+dfsg1
[rustc.git] / src / tools / clippy / src / docs / double_must_use.txt
CommitLineData
f2b60f7d
FG
1### What it does
2Checks for a `#[must_use]` attribute without
3further information on functions and methods that return a type already
4marked as `#[must_use]`.
5
6### Why is this bad?
7The attribute isn't needed. Not using the result
8will already be reported. Alternatively, one can add some text to the
9attribute to improve the lint message.
10
11### Examples
12```
13#[must_use]
14fn double_must_use() -> Result<(), ()> {
15 unimplemented!();
16}
17```