warning: lifetime parameter `'impl0` only used once
--> src/lib.rs:7:19
|
7 | impl<T> Trait for &T {}
| ^
| |
| this lifetime...
| ...is used only here
|
note: the lint level is defined here
--> src/lib.rs:1:9
|
1 | #![warn(single_use_lifetimes)]
| ^^^^^^^^^^^^^^^^^^^^
help: elide the single-use lifetime
|
7 - impl<T> Trait for &T {}
7 + impl<T {}
|
playground
The suggestion is particularly helpful :laughing: