mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-09 20:11:09 +00:00
Do not panic while panicking (#7167)
* Do not panic while panicking * Update primitives/runtime/src/lib.rs Co-authored-by: David <dvdplm@gmail.com> * Move function to `sp-std` Co-authored-by: David <dvdplm@gmail.com>
This commit is contained in:
@@ -53,3 +53,12 @@ pub mod borrow {
|
||||
pub use core::borrow::*;
|
||||
pub use alloc::borrow::*;
|
||||
}
|
||||
|
||||
pub mod thread {
|
||||
/// Returns if the current thread is panicking.
|
||||
///
|
||||
/// In wasm this always returns `false`, as we abort on any panic.
|
||||
pub fn panicking() -> bool {
|
||||
false
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user