diff options
| author | Michael Goulet <michael@errs.io> | 2024-07-06 11:54:22 -0400 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2024-07-07 00:12:35 -0400 |
| commit | 58aad3c72c32936b49f92f552e0157b9c8c862ee (patch) | |
| tree | f5f7e8da4f7fd586a1fbbd6560e2d82476c779f9 /compiler/rustc_ty_utils/src | |
| parent | 289deb9ed78af2a042b0a326003162c4b770b121 (diff) | |
iter_identity is a better name
Diffstat (limited to 'compiler/rustc_ty_utils/src')
| -rw-r--r-- | compiler/rustc_ty_utils/src/opaque_types.rs | 6 | ||||
| -rw-r--r-- | compiler/rustc_ty_utils/src/sig_types.rs | 2 |
2 files changed, 3 insertions, 5 deletions
diff --git a/compiler/rustc_ty_utils/src/opaque_types.rs b/compiler/rustc_ty_utils/src/opaque_types.rs index 686f2f04ad9..5e91320f897 100644 --- a/compiler/rustc_ty_utils/src/opaque_types.rs +++ b/compiler/rustc_ty_utils/src/opaque_types.rs @@ -169,10 +169,8 @@ impl<'tcx> OpaqueTypeCollector<'tcx> { // Collect opaque types nested within the associated type bounds of this opaque type. // We use identity args here, because we already know that the opaque type uses // only generic parameters, and thus instantiating would not give us more information. - for (pred, span) in self - .tcx - .explicit_item_bounds(alias_ty.def_id) - .instantiate_identity_iter_copied() + for (pred, span) in + self.tcx.explicit_item_bounds(alias_ty.def_id).iter_identity_copied() { trace!(?pred); self.visit_spanned(span, pred); diff --git a/compiler/rustc_ty_utils/src/sig_types.rs b/compiler/rustc_ty_utils/src/sig_types.rs index 97a1b94263e..eb6cb369974 100644 --- a/compiler/rustc_ty_utils/src/sig_types.rs +++ b/compiler/rustc_ty_utils/src/sig_types.rs @@ -62,7 +62,7 @@ pub fn walk_types<'tcx, V: SpannedTypeVisitor<'tcx>>( } } DefKind::OpaqueTy => { - for (pred, span) in tcx.explicit_item_bounds(item).instantiate_identity_iter_copied() { + for (pred, span) in tcx.explicit_item_bounds(item).iter_identity_copied() { try_visit!(visitor.visit(span, pred)); } } |
