Skip to content

Commit

Permalink
Add sugar for &pin (const|mut) types
Browse files Browse the repository at this point in the history
  • Loading branch information
eholk committed Oct 7, 2024
1 parent 65d941d commit c038c30
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions clippy_utils/src/ast_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -753,6 +753,9 @@ pub fn eq_ty(l: &Ty, r: &Ty) -> bool {
(Ref(ll, l), Ref(rl, r)) => {
both(ll.as_ref(), rl.as_ref(), |l, r| eq_id(l.ident, r.ident)) && l.mutbl == r.mutbl && eq_ty(&l.ty, &r.ty)
},
(PinnedRef(ll, l), PinnedRef(rl, r)) => {
both(ll.as_ref(), rl.as_ref(), |l, r| eq_id(l.ident, r.ident)) && l.mutbl == r.mutbl && eq_ty(&l.ty, &r.ty)
},
(BareFn(l), BareFn(r)) => {
l.safety == r.safety
&& eq_ext(&l.ext, &r.ext)
Expand Down

0 comments on commit c038c30

Please sign in to comment.