Skip to content

Commit

Permalink
should_implement_trait - filter on explicit lifetime param only
Browse files Browse the repository at this point in the history
  • Loading branch information
tnielens committed Jul 29, 2020
1 parent f7a73f1 commit d7e3f34
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clippy_lints/src/methods/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1502,7 +1502,7 @@ impl<'tcx> LateLintPass<'tcx> for Methods {
!impl_item.generics.params.iter()
.any(|p| matches!(
p.kind,
hir::GenericParamKind::Lifetime { .. }))
hir::GenericParamKind::Lifetime { kind: hir::LifetimeParamKind::Explicit }))
};
if name == method_name &&
sig.decl.inputs.len() == n_args &&
Expand Down

0 comments on commit d7e3f34

Please sign in to comment.