diff options
Diffstat (limited to 'library/panic_unwind/src/dummy.rs')
| -rw-r--r-- | library/panic_unwind/src/dummy.rs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/library/panic_unwind/src/dummy.rs b/library/panic_unwind/src/dummy.rs new file mode 100644 index 00000000000..4667ede2baa --- /dev/null +++ b/library/panic_unwind/src/dummy.rs @@ -0,0 +1,15 @@ +//! Unwinding for *wasm32* target. +//! +//! Right now we don't support this, so this is just stubs. + +use alloc::boxed::Box; +use core::any::Any; +use core::intrinsics; + +pub unsafe fn cleanup(_ptr: *mut u8) -> Box<dyn Any + Send> { + intrinsics::abort() +} + +pub unsafe fn panic(_data: Box<dyn Any + Send>) -> u32 { + intrinsics::abort() +} |
