@@ -160,7 +160,7 @@ fn visit_implementation_of_dispatch_from_dyn(tcx: TyCtxt<'_>, impl_did: LocalDef
160160 use rustc_type_ir:: sty:: TyKind :: * ;
161161 match ( source. kind ( ) , target. kind ( ) ) {
162162 ( & Ref ( r_a, _, mutbl_a) , Ref ( r_b, _, mutbl_b) )
163- if infcx. at ( & cause, param_env) . eq ( DefineOpaqueTypes :: No , r_a, * r_b) . is_ok ( )
163+ if infcx. at ( & cause, param_env) . eq ( DefineOpaqueTypes :: Yes , r_a, * r_b) . is_ok ( )
164164 && mutbl_a == * mutbl_b => { }
165165 ( & RawPtr ( tm_a) , & RawPtr ( tm_b) ) if tm_a. mutbl == tm_b. mutbl => ( ) ,
166166 ( & Adt ( def_a, substs_a) , & Adt ( def_b, substs_b) )
@@ -205,7 +205,7 @@ fn visit_implementation_of_dispatch_from_dyn(tcx: TyCtxt<'_>, impl_did: LocalDef
205205 }
206206
207207 if let Ok ( ok) =
208- infcx. at ( & cause, param_env) . eq ( DefineOpaqueTypes :: No , ty_a, ty_b)
208+ infcx. at ( & cause, param_env) . eq ( DefineOpaqueTypes :: Yes , ty_a, ty_b)
209209 {
210210 if ok. obligations . is_empty ( ) {
211211 create_err (
@@ -427,7 +427,7 @@ pub fn coerce_unsized_info<'tcx>(tcx: TyCtxt<'tcx>, impl_did: LocalDefId) -> Coe
427427 // we may have to evaluate constraint
428428 // expressions in the course of execution.)
429429 // See e.g., #41936.
430- if let Ok ( ok) = infcx. at ( & cause, param_env) . eq ( DefineOpaqueTypes :: No , a, b) {
430+ if let Ok ( ok) = infcx. at ( & cause, param_env) . eq ( DefineOpaqueTypes :: Yes , a, b) {
431431 if ok. obligations . is_empty ( ) {
432432 return None ;
433433 }
0 commit comments