]> git.lizzy.rs Git - rust.git/blob - tests/ui/must_use_unit.stderr
Auto merge of #9684 - kraktus:ref_option_ref, r=xFrednet
[rust.git] / tests / ui / must_use_unit.stderr
1 error: this unit-returning function has a `#[must_use]` attribute
2   --> $DIR/must_use_unit.rs:11:1
3    |
4 LL | #[must_use]
5    | ----------- help: remove the attribute
6 LL | pub fn must_use_default() {}
7    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
8    |
9    = note: `-D clippy::must-use-unit` implied by `-D warnings`
10
11 error: this unit-returning function has a `#[must_use]` attribute
12   --> $DIR/must_use_unit.rs:14:1
13    |
14 LL | #[must_use]
15    | ----------- help: remove the attribute
16 LL | pub fn must_use_unit() -> () {}
17    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
18
19 error: this unit-returning function has a `#[must_use]` attribute
20   --> $DIR/must_use_unit.rs:17:1
21    |
22 LL | #[must_use = "With note"]
23    | ------------------------- help: remove the attribute
24 LL | pub fn must_use_with_note() {}
25    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
26
27 error: aborting due to 3 previous errors
28