File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -39,6 +39,9 @@ cfg_if::cfg_if! {
39
39
if #[ cfg( miri) ] {
40
40
#[ path = "miri.rs" ]
41
41
mod imp;
42
+ // Export this at the root of the crate so that Miri
43
+ // has a stable palce to look it up
44
+ pub use imp:: miri_panic_trampoline;
42
45
} else if #[ cfg( target_os = "emscripten" ) ] {
43
46
#[ path = "emcc.rs" ]
44
47
mod imp;
@@ -98,7 +101,4 @@ pub unsafe extern "C" fn __rust_start_panic(payload: usize) -> u32 {
98
101
imp:: panic ( Box :: from_raw ( ( * payload) . box_me_up ( ) ) )
99
102
}
100
103
101
- // A dummy helper function for Miri.
102
- // Used to push an empty stack frame when we start unwinding
103
- #[ cfg( miri) ]
104
- pub fn miri_panic_trampoline ( ) { }
104
+
Original file line number Diff line number Diff line change @@ -21,3 +21,8 @@ pub unsafe fn cleanup(ptr: *mut u8) -> Box<dyn Any + Send> {
21
21
fn rust_eh_personality ( ) {
22
22
unsafe { core:: intrinsics:: abort ( ) }
23
23
}
24
+
25
+ // A dummy helper function for Miri.
26
+ // Used to push an empty stack frame when we start unwinding
27
+ #[ cfg( miri) ]
28
+ pub fn miri_panic_trampoline ( ) { }
You can’t perform that action at this time.
0 commit comments