2022-11-21 19:34:47 +00:00
|
|
|
error: the following explicit lifetimes could be elided: 'a
|
2020-10-09 10:45:29 +00:00
|
|
|
--> $DIR/needless_lifetimes_impl_trait.rs:15:5
|
|
|
|
|
|
|
|
|
LL | fn baz<'a>(&'a self) -> impl Foo + 'a {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
note: the lint level is defined here
|
|
|
|
--> $DIR/needless_lifetimes_impl_trait.rs:1:9
|
|
|
|
|
|
|
|
|
LL | #![deny(clippy::needless_lifetimes)]
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
2023-02-10 13:01:19 +00:00
|
|
|
help: elide the lifetimes
|
|
|
|
|
|
|
|
|
LL - fn baz<'a>(&'a self) -> impl Foo + 'a {
|
|
|
|
LL + fn baz(&self) -> impl Foo + '_ {
|
|
|
|
|
|
2020-10-09 10:45:29 +00:00
|
|
|
|
|
|
|
error: aborting due to previous error
|
|
|
|
|