Skip to content

Commit 64949e1

Browse files
committed
Resolve needless_lifetimes clippy lint
warning: the following explicit lifetimes could be elided: 'a --> src/unindent.rs:83:6 | 83 | impl<'a, T: ?Sized + Unindent> Unindent for &'a T { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes = note: `-W clippy::needless-lifetimes` implied by `-W clippy::all` = help: to override `-W clippy::all` add `#[allow(clippy::needless_lifetimes)]` help: elide the lifetimes | 83 - impl<'a, T: ?Sized + Unindent> Unindent for &'a T { 83 + impl<T: ?Sized + Unindent> Unindent for &T { |
1 parent 0d37b42 commit 64949e1

File tree

3 files changed

+1
-3
lines changed

3 files changed

+1
-3
lines changed

src/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,6 @@
127127
clippy::from_iter_instead_of_collect,
128128
clippy::module_name_repetitions,
129129
clippy::needless_doctest_main,
130-
clippy::needless_lifetimes,
131130
clippy::needless_pass_by_value,
132131
clippy::trivially_copy_pass_by_ref,
133132
clippy::type_complexity

src/unindent.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ impl Unindent for [u8] {
8080
}
8181
}
8282

83-
impl<'a, T: ?Sized + Unindent> Unindent for &'a T {
83+
impl<T: ?Sized + Unindent> Unindent for &T {
8484
type Output = T::Output;
8585

8686
fn unindent(&self) -> Self::Output {

unindent/src/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@
5151
clippy::module_name_repetitions,
5252
clippy::must_use_candidate,
5353
clippy::needless_doctest_main,
54-
clippy::needless_lifetimes,
5554
clippy::trivially_copy_pass_by_ref,
5655
clippy::type_complexity
5756
)]

0 commit comments

Comments
 (0)