Skip to content

Commit de40841

Browse files
committed
normalzie before resolving associated items
1 parent 124673b commit de40841

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

compiler/rustc_ty_utils/src/instance.rs

+1
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,7 @@ fn inner_resolve_instance<'tcx>(
148148

149149
let result = if let Some(trait_def_id) = tcx.trait_of_item(def.did) {
150150
debug!(" => associated item, attempting to find impl in param_env {:#?}", param_env);
151+
let substs = tcx.normalize_erasing_regions(param_env, substs);
151152
resolve_associated_item(tcx, def.did, param_env, trait_def_id, substs)
152153
} else {
153154
let ty = tcx.type_of(def.def_id_for_type_of());

0 commit comments

Comments
 (0)