enable serde serialization for block and blockheader

This commit is contained in:
Tamas Blummer 2019-08-24 14:26:18 +02:00
parent 24361dd2f1
commit 38d5ae4e3f
1 changed files with 2 additions and 0 deletions

View File

@ -205,6 +205,8 @@ impl BitcoinHash for Block {
impl_consensus_encoding!(BlockHeader, version, prev_blockhash, merkle_root, time, bits, nonce); impl_consensus_encoding!(BlockHeader, version, prev_blockhash, merkle_root, time, bits, nonce);
impl_consensus_encoding!(Block, header, txdata); impl_consensus_encoding!(Block, header, txdata);
serde_struct_impl!(BlockHeader, version, prev_blockhash, merkle_root, time, bits, nonce);
serde_struct_impl!(Block, header, txdata);
#[cfg(test)] #[cfg(test)]
mod tests { mod tests {