mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 00:01:03 +00:00
Update parity-scale-codec to 2.0 (#7994)
* update cargo.toml * use 2.0 in mmmr
This commit is contained in:
committed by
GitHub
parent
bea4a6524d
commit
f48296e9ad
@@ -12,7 +12,7 @@ description = "FRAME Merkle Mountain Range pallet."
|
||||
targets = ["x86_64-unknown-linux-gnu"]
|
||||
|
||||
[dependencies]
|
||||
codec = { package = "parity-scale-codec", version = "1.3.6", default-features = false }
|
||||
codec = { package = "parity-scale-codec", version = "2.0.0", default-features = false }
|
||||
frame-benchmarking = { version = "2.0.0", default-features = false, path = "../benchmarking", optional = true }
|
||||
frame-support = { version = "2.0.0", default-features = false, path = "../support" }
|
||||
frame-system = { version = "2.0.0", default-features = false, path = "../system" }
|
||||
|
||||
@@ -12,7 +12,7 @@ description = "FRAME Merkle Mountain Range primitives."
|
||||
targets = ["x86_64-unknown-linux-gnu"]
|
||||
|
||||
[dependencies]
|
||||
codec = { package = "parity-scale-codec", version = "1.3.6", default-features = false }
|
||||
codec = { package = "parity-scale-codec", version = "2.0.0", default-features = false }
|
||||
frame-support = { version = "2.0.0", default-features = false, path = "../../support" }
|
||||
frame-system = { version = "2.0.0", default-features = false, path = "../../system" }
|
||||
serde = { version = "1.0.101", optional = true, features = ["derive"] }
|
||||
|
||||
@@ -127,7 +127,7 @@ mod encoding {
|
||||
}
|
||||
|
||||
impl<H: traits::Hash, L: FullLeaf> codec::Encode for DataOrHash<H, L> {
|
||||
fn encode_to<T: codec::Output>(&self, dest: &mut T) {
|
||||
fn encode_to<T: codec::Output + ?Sized>(&self, dest: &mut T) {
|
||||
match self {
|
||||
Self::Data(l) => l.using_encoded(
|
||||
|data| Either::<&[u8], &H::Output>::Left(data).encode_to(dest), false
|
||||
|
||||
Reference in New Issue
Block a user