1 // ignore-wasm32-bare compiled with panic=abort by default
3 // Test that we generate StorageDead on unwind paths for generators.
5 // Basic block and local names can safely change, but the StorageDead statements
8 #![feature(generators, generator_trait)]
32 // START rustc.main-{{closure}}.StateTransform.before.mir
48 // _2 = Foo(const 5i32,);
50 // _3 = Bar(const 6i32,);
52 // _1 = suspend(move _5) -> [resume: bb2, drop: bb4];
62 // _6 = const take::<Foo>(move _7) -> [return: bb7, unwind: bb9];
71 // drop(_2) -> [return: bb5, unwind: bb3];
75 // drop(_1) -> [return: bb6, unwind: bb1];
86 // _8 = const take::<Bar>(move _9) -> [return: bb10, unwind: bb11];
104 // drop(_1) -> [return: bb12, unwind: bb1];
114 // END rustc.main-{{closure}}.StateTransform.before.mir