File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed
rust/immutable-ledger/src Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -61,9 +61,9 @@ pub struct BlockHeaderSize(usize);
6161#[ derive( Debug , Clone , PartialEq ) ]
6262pub struct EncodedBlockHeader ( pub Vec < u8 > ) ;
6363
64- /// Decoded block data
64+ /// Block data
6565#[ derive( Debug , Clone , PartialEq ) ]
66- pub struct DecodedBlockData ( Vec < u8 > ) ;
66+ pub struct BlockData ( Vec < u8 > ) ;
6767
6868/// Encoded block data as cbor
6969#[ derive( Debug , Clone , PartialEq ) ]
@@ -82,7 +82,7 @@ pub struct Signatures(Vec<Signature>);
8282pub struct ValidatorKeys ( pub Vec < [ u8 ; SECRET_KEY_LENGTH ] > ) ;
8383
8484/// Decoded block
85- pub type DecodedBlock = ( DecodedBlockHeader , DecodedBlockData , Signatures ) ;
85+ pub type DecodedBlock = ( DecodedBlockHeader , BlockData , Signatures ) ;
8686
8787/// Block header
8888pub struct BlockHeader (
@@ -228,11 +228,7 @@ pub fn decode_block(encoded_block: &[u8]) -> anyhow::Result<DecodedBlock> {
228228 sigs. push ( Signature :: from_bytes ( & sig) ) ;
229229 }
230230
231- Ok ( (
232- block_hdr,
233- DecodedBlockData ( block_data. to_vec ( ) ) ,
234- Signatures ( sigs) ,
235- ) )
231+ Ok ( ( block_hdr, BlockData ( block_data. to_vec ( ) ) , Signatures ( sigs) ) )
236232}
237233
238234/// Produce BLAKE3 hash
You can’t perform that action at this time.
0 commit comments