diff options
| author | Yoshitomo Nakanishi <yurayura.rounin.3@gmail.com> | 2024-03-05 20:19:05 +0100 |
|---|---|---|
| committer | Yoshitomo Nakanishi <yurayura.rounin.3@gmail.com> | 2024-03-07 13:56:29 +0100 |
| commit | 96699347989d1e6fc43805dd374f8289cbb8fcad (patch) | |
| tree | 7dbf2330079ca3a34fd76bf33ee61174dc4841fa /compiler/rustc_trait_selection/src/traits/specialize/mod.rs | |
| parent | 8c9a75b3238b66592779d6b240dbf78eacefebb8 (diff) | |
| download | rust-96699347989d1e6fc43805dd374f8289cbb8fcad.tar.gz rust-96699347989d1e6fc43805dd374f8289cbb8fcad.zip | |
Apply `EarlyBinder` only to `TraitRef` in `ImplTraitHeader`
Diffstat (limited to 'compiler/rustc_trait_selection/src/traits/specialize/mod.rs')
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/specialize/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/specialize/mod.rs b/compiler/rustc_trait_selection/src/traits/specialize/mod.rs index f5bc6c3ad2c..27dd8f26489 100644 --- a/compiler/rustc_trait_selection/src/traits/specialize/mod.rs +++ b/compiler/rustc_trait_selection/src/traits/specialize/mod.rs @@ -169,7 +169,7 @@ pub(super) fn specializes(tcx: TyCtxt<'_>, (impl1_def_id, impl2_def_id): (DefId, } } - let impl1_trait_header = tcx.impl_trait_header(impl1_def_id).unwrap().instantiate_identity(); + let impl1_trait_header = tcx.impl_trait_header(impl1_def_id).unwrap(); // We determine whether there's a subset relationship by: // @@ -198,7 +198,7 @@ pub(super) fn specializes(tcx: TyCtxt<'_>, (impl1_def_id, impl2_def_id): (DefId, fulfill_implication( &infcx, penv, - impl1_trait_header.trait_ref, + impl1_trait_header.trait_ref.instantiate_identity(), impl1_def_id, impl2_def_id, |_, _| ObligationCause::dummy(), |
