mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-09 20:11:09 +00:00
sp-debug-derive: Add force-debug feature (#9996)
* sp-debug-derive: Add `force-debug` feature Sometimes users want to have proper debug information even inside the wasm runtime, when they use `RuntimeDebug`. To not fork Substrate to change a type to a normal `Debug` derive, this pr introduces the `force-debug` feature. This feature can be enabled by the user in their runtime and then the types will use the normal Debug derive instead of printing `wasm:stripped`. * Fixes
This commit is contained in:
@@ -43,7 +43,7 @@ pub fn debug_derive(ast: DeriveInput) -> proc_macro::TokenStream {
|
||||
gen.into()
|
||||
}
|
||||
|
||||
#[cfg(not(feature = "std"))]
|
||||
#[cfg(all(not(feature = "std"), not(feature = "force-debug")))]
|
||||
mod implementation {
|
||||
use super::*;
|
||||
|
||||
@@ -58,7 +58,7 @@ mod implementation {
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "std")]
|
||||
#[cfg(any(feature = "std", feature = "force-debug"))]
|
||||
mod implementation {
|
||||
use super::*;
|
||||
use proc_macro2::Span;
|
||||
|
||||
Reference in New Issue
Block a user