region error cleanup
- require `TypeErrCtxt` to always result in an error - move `resolve_regions_and_report_errors` to the `ObligationCtxt` - merge `process_registered_region_obligations` into `resolve_regions`
This commit is contained in:
parent
0d7ed3ba84
commit
a19adefa0e
13 changed files with 183 additions and 236 deletions
|
@ -452,11 +452,8 @@ fn check_opaque_meets_bounds<'tcx>(
|
|||
hir::OpaqueTyOrigin::FnReturn(..) | hir::OpaqueTyOrigin::AsyncFn(..) => {}
|
||||
// Can have different predicates to their defining use
|
||||
hir::OpaqueTyOrigin::TyAlias => {
|
||||
let outlives_environment = OutlivesEnvironment::new(param_env);
|
||||
let _ = infcx.err_ctxt().check_region_obligations_and_report_errors(
|
||||
defining_use_anchor,
|
||||
&outlives_environment,
|
||||
);
|
||||
let outlives_env = OutlivesEnvironment::new(param_env);
|
||||
let _ = ocx.resolve_regions_and_report_errors(defining_use_anchor, &outlives_env);
|
||||
}
|
||||
}
|
||||
// Clean up after ourselves
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue