Skip to content

Commit 925c842

Browse files
committed
Auto merge of #137927 - matthiaskrgr:rollup-yj463ns, r=matthiaskrgr
Rollup of 9 pull requests Successful merges: - #132388 (Implement `#[cfg]` in `where` clauses) - #134900 (Fix parsing of ranges after unary operators) - #136938 (Remove `:` from `stack-protector-heuristics-effect.rs` Filecheck Pattern) - #137054 (Make phantom variance markers transparent) - #137525 (Simplify parallelization in test-float-parse) - #137618 (Skip `tidy` in pre-push hook if the user is deleting a remote branch) - #137741 (Stop using `hash_raw_entry` in `CodegenCx::const_str`) - #137849 (Revert "Remove Win SDK 10.0.26100.0 from CI") - #137862 (ensure we always print all --print options in help) r? `@ghost` `@rustbot` modify labels: rollup
2 parents bebd594 + 299985c commit 925c842

File tree

1 file changed

+14
-13
lines changed
  • clippy_utils/src/ast_utils

1 file changed

+14
-13
lines changed

clippy_utils/src/ast_utils/mod.rs

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -682,19 +682,20 @@ pub fn eq_generics(l: &Generics, r: &Generics) -> bool {
682682

683683
pub fn eq_where_predicate(l: &WherePredicate, r: &WherePredicate) -> bool {
684684
use WherePredicateKind::*;
685-
match (&l.kind, &r.kind) {
686-
(BoundPredicate(l), BoundPredicate(r)) => {
687-
over(&l.bound_generic_params, &r.bound_generic_params, |l, r| {
688-
eq_generic_param(l, r)
689-
}) && eq_ty(&l.bounded_ty, &r.bounded_ty)
690-
&& over(&l.bounds, &r.bounds, eq_generic_bound)
691-
},
692-
(RegionPredicate(l), RegionPredicate(r)) => {
693-
eq_id(l.lifetime.ident, r.lifetime.ident) && over(&l.bounds, &r.bounds, eq_generic_bound)
694-
},
695-
(EqPredicate(l), EqPredicate(r)) => eq_ty(&l.lhs_ty, &r.lhs_ty) && eq_ty(&l.rhs_ty, &r.rhs_ty),
696-
_ => false,
697-
}
685+
over(&l.attrs, &r.attrs, eq_attr)
686+
&& match (&l.kind, &r.kind) {
687+
(BoundPredicate(l), BoundPredicate(r)) => {
688+
over(&l.bound_generic_params, &r.bound_generic_params, |l, r| {
689+
eq_generic_param(l, r)
690+
}) && eq_ty(&l.bounded_ty, &r.bounded_ty)
691+
&& over(&l.bounds, &r.bounds, eq_generic_bound)
692+
},
693+
(RegionPredicate(l), RegionPredicate(r)) => {
694+
eq_id(l.lifetime.ident, r.lifetime.ident) && over(&l.bounds, &r.bounds, eq_generic_bound)
695+
},
696+
(EqPredicate(l), EqPredicate(r)) => eq_ty(&l.lhs_ty, &r.lhs_ty) && eq_ty(&l.rhs_ty, &r.rhs_ty),
697+
_ => false,
698+
}
698699
}
699700

700701
pub fn eq_use_tree(l: &UseTree, r: &UseTree) -> bool {

0 commit comments

Comments
 (0)