summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/crashes/needless_lifetimes_impl_trait.stderr
blob: 0b0e0ad2684a902adc90a854f25345394ec4ea14 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
error: the following explicit lifetimes could be elided: 'a
  --> $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)]
   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^
help: elide the lifetimes
   |
LL -     fn baz<'a>(&'a self) -> impl Foo + 'a {
LL +     fn baz(&self) -> impl Foo + '_ {
   |

error: aborting due to previous error