Do not store visibility in *ItemRef.

This commit is contained in:
Camille GILLOT 2021-07-15 22:19:39 +02:00
parent 5ecc8ad846
commit d7795d302a
16 changed files with 49 additions and 70 deletions

View file

@ -209,7 +209,7 @@ fn extend_cause_with_original_assoc_item_obligation<'tcx>(
_ => return,
};
let fix_span =
|impl_item_ref: &hir::ImplItemRef<'_>| match tcx.hir().impl_item(impl_item_ref.id).kind {
|impl_item_ref: &hir::ImplItemRef| match tcx.hir().impl_item(impl_item_ref.id).kind {
hir::ImplItemKind::Const(ty, _) | hir::ImplItemKind::TyAlias(ty) => ty.span,
_ => impl_item_ref.span,
};