1 error: missing `#[must_use]` attribute on a method returning `Self`
2 --> $DIR/return_self_not_must_use.rs:8:5
4 LL | fn what(&self) -> Self;
5 | ^^^^^^^^^^^^^^^^^^^^^^^
7 = note: `-D clippy::return-self-not-must-use` implied by `-D warnings`
8 = help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
10 error: missing `#[must_use]` attribute on a method returning `Self`
11 --> $DIR/return_self_not_must_use.rs:18:5
13 LL | / pub fn foo(&self) -> Self {
18 = help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
20 error: missing `#[must_use]` attribute on a method returning `Self`
21 --> $DIR/return_self_not_must_use.rs:21:5
23 LL | / pub fn bar(self) -> Self {
28 = help: consider adding the `#[must_use]` attribute to the method or directly to the `Self` type
30 error: aborting due to 3 previous errors