1 // min-llvm-version: 13.0.0
6 #![feature(asm_sym, asm_unwind)]
9 use std::panic::{catch_unwind, resume_unwind, AssertUnwindSafe};
11 struct Foo<'a>(&'a mut bool);
13 impl Drop for Foo<'_> {
19 extern "C" fn panicky() {
20 resume_unwind(Box::new(()));
25 catch_unwind(AssertUnwindSafe(|| {
36 .expect_err("expected a panic");
37 assert_eq!(*flag, false);