pub struct Message<'a> {
pub prefix: &'a [u8],
pub body: &'a [u8],
pub tail: &'a [u8],
}Expand description
One message to hash: an optional shared prefix plus a body
Keeping the prefix separate lets the Merkle-leaf case skip materialising
prefix || body per message; the driver reads from both slices directly.
Fields§
§prefix: &'a [u8]§body: &'a [u8]§tail: &'a [u8]Optional third segment, hashed after body
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Message<'a>
impl<'a> RefUnwindSafe for Message<'a>
impl<'a> Send for Message<'a>
impl<'a> Sync for Message<'a>
impl<'a> Unpin for Message<'a>
impl<'a> UnsafeUnpin for Message<'a>
impl<'a> UnwindSafe for Message<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more