mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 19:17:58 +00:00
wasm-override: Support checking spec_name (#10380)
This adds support to the wasm-override feature to compare the spec_name. If the spec_name doesn't match, a warning will be printed and the override will be ignored.
This commit is contained in:
@@ -92,6 +92,18 @@ impl AsRef<[u8]> for RuntimeString {
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "std")]
|
||||
impl std::ops::Deref for RuntimeString {
|
||||
type Target = str;
|
||||
|
||||
fn deref(&self) -> &str {
|
||||
match self {
|
||||
Self::Borrowed(val) => &val,
|
||||
Self::Owned(val) => &val,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl Encode for RuntimeString {
|
||||
fn encode(&self) -> Vec<u8> {
|
||||
match self {
|
||||
|
||||
Reference in New Issue
Block a user