Add unreachable() after calls to eh_unwind_resume.

This commit is contained in:
Mark Simulacrum 2016-12-19 20:09:51 -07:00
parent 07cf2a9005
commit 654131cb53
2 changed files with 2 additions and 0 deletions

View file

@ -93,6 +93,7 @@ impl<'tcx> DropValue<'tcx> {
} else {
let exc_ptr = resume_bcx.extract_value(lp, 0);
resume_bcx.call(fcx.eh_unwind_resume().reify(fcx.ccx), &[exc_ptr], None);
resume_bcx.unreachable();
}
UnwindKind::LandingPad
};

View file

@ -130,6 +130,7 @@ impl<'a, 'tcx> MirContext<'a, 'tcx> {
&[exc_ptr],
cleanup_bundle,
);
bcx.unreachable();
}
}
}