mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-23 21:23:56 +00:00
Use pred not binder
This commit is contained in:
parent
f06eeaf982
commit
7c3b6a63ad
1 changed files with 1 additions and 1 deletions
|
@ -117,7 +117,7 @@ impl<'tcx> LateLintPass<'tcx> for NeedlessPassByValue {
|
|||
// Note that we do not want to deal with qualified predicates here.
|
||||
let binder = obligation.predicate.bound_atom();
|
||||
match binder.skip_binder() {
|
||||
ty::PredicateAtom::Trait(pred, _) if !binder.has_escaping_bound_vars() => {
|
||||
ty::PredicateAtom::Trait(pred, _) if !pred.has_escaping_bound_vars() => {
|
||||
if pred.def_id() == sized_trait {
|
||||
return None;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue