Fix FFI-unwind unsoundness with mixed panic mode
This commit is contained in:
parent
09d52bc5d4
commit
6ef2033884
11 changed files with 212 additions and 14 deletions
|
@ -57,6 +57,7 @@ mod dest_prop;
|
|||
pub mod dump_mir;
|
||||
mod early_otherwise_branch;
|
||||
mod elaborate_drops;
|
||||
mod ffi_unwind_calls;
|
||||
mod function_item_references;
|
||||
mod generator;
|
||||
mod inline;
|
||||
|
@ -96,6 +97,7 @@ pub fn provide(providers: &mut Providers) {
|
|||
check_unsafety::provide(providers);
|
||||
check_packed_ref::provide(providers);
|
||||
coverage::query::provide(providers);
|
||||
ffi_unwind_calls::provide(providers);
|
||||
shim::provide(providers);
|
||||
*providers = Providers {
|
||||
mir_keys,
|
||||
|
@ -221,6 +223,9 @@ fn mir_const<'tcx>(
|
|||
}
|
||||
}
|
||||
|
||||
// has_ffi_unwind_calls query uses the raw mir, so make sure it is run.
|
||||
tcx.ensure().has_ffi_unwind_calls(def.did);
|
||||
|
||||
let mut body = tcx.mir_built(def).steal();
|
||||
|
||||
rustc_middle::mir::dump_mir(tcx, None, "mir_map", &0, &body, |_, _| Ok(()));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue