Skip to content

Commit

Permalink
Ignore needless_lifetimes clippy lint
Browse files Browse the repository at this point in the history
    warning: the following explicit lifetimes could be elided: 'a
      --> src/to_tokens.rs:78:6
       |
    78 | impl<'a, T: ?Sized + ToTokens> ToTokens 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
       |
    78 - impl<'a, T: ?Sized + ToTokens> ToTokens for &'a T {
    78 + impl<T: ?Sized + ToTokens> ToTokens for &T {
       |

    warning: the following explicit lifetimes could be elided: 'a
      --> src/to_tokens.rs:84:6
       |
    84 | impl<'a, T: ?Sized + ToTokens> ToTokens for &'a mut T {
       |      ^^                                      ^^
       |
       = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    help: elide the lifetimes
       |
    84 - impl<'a, T: ?Sized + ToTokens> ToTokens for &'a mut T {
    84 + impl<T: ?Sized + ToTokens> ToTokens for &mut T {
       |

    warning: the following explicit lifetimes could be elided: 'a
      --> src/to_tokens.rs:90:6
       |
    90 | impl<'a, T: ?Sized + ToOwned + ToTokens> ToTokens for Cow<'a, T> {
       |      ^^                                                   ^^
       |
       = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    help: elide the lifetimes
       |
    90 - impl<'a, T: ?Sized + ToOwned + ToTokens> ToTokens for Cow<'a, T> {
    90 + impl<T: ?Sized + ToOwned + ToTokens> ToTokens for Cow<'_, T> {
       |

    warning: the following explicit lifetimes could be elided: 'a
       --> src/runtime.rs:105:14
        |
    105 |     impl<'q, 'a, T: RepAsIteratorExt<'q> + ?Sized> RepAsIteratorExt<'q> for &'a T {
        |              ^^                                                              ^^
        |
        = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    help: elide the lifetimes
        |
    105 -     impl<'q, 'a, T: RepAsIteratorExt<'q> + ?Sized> RepAsIteratorExt<'q> for &'a T {
    105 +     impl<'q, T: RepAsIteratorExt<'q> + ?Sized> RepAsIteratorExt<'q> for &T {
        |

    warning: the following explicit lifetimes could be elided: 'a
       --> src/runtime.rs:113:14
        |
    113 |     impl<'q, 'a, T: RepAsIteratorExt<'q> + ?Sized> RepAsIteratorExt<'q> for &'a mut T {
        |              ^^                                                              ^^
        |
        = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    help: elide the lifetimes
        |
    113 -     impl<'q, 'a, T: RepAsIteratorExt<'q> + ?Sized> RepAsIteratorExt<'q> for &'a mut T {
    113 +     impl<'q, T: RepAsIteratorExt<'q> + ?Sized> RepAsIteratorExt<'q> for &mut T {
        |

    warning: the following explicit lifetimes could be elided: 'a
       --> src/runtime.rs:305:10
        |
    305 |     impl<'a> Iterator for Lifetime<'a> {
        |          ^^                        ^^
        |
        = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    help: elide the lifetimes
        |
    305 -     impl<'a> Iterator for Lifetime<'a> {
    305 +     impl Iterator for Lifetime<'_> {
        |

    warning: the following explicit lifetimes could be elided: 'a
       --> src/runtime.rs:337:10
        |
    337 |     impl<'a> Iterator for Lifetime<'a> {
        |          ^^                        ^^
        |
        = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    help: elide the lifetimes
        |
    337 -     impl<'a> Iterator for Lifetime<'a> {
    337 +     impl Iterator for Lifetime<'_> {
        |
  • Loading branch information
dtolnay committed Oct 6, 2024
1 parent 6cff24b commit 31d7a01
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@
clippy::missing_errors_doc,
clippy::missing_panics_doc,
clippy::module_name_repetitions,
clippy::needless_lifetimes,
// false positive https://github.com/rust-lang/rust-clippy/issues/6983
clippy::wrong_self_convention,
)]
Expand Down

0 comments on commit 31d7a01

Please sign in to comment.