pub struct Sha256Compression { /* private fields */ }Expand description
A two-to-one compression function for SHA-256 digests.
One raw block compression of left || right, from a domain-separated initial state.
This is not a full hash of the pair: there is no padding block and no length suffix.
Implementations§
Source§impl Sha256Compression
impl Sha256Compression
Sourcepub const fn initial_state(&self) -> &[u32; 8]
pub const fn initial_state(&self) -> &[u32; 8]
The domain-separated state every compression starts from.
A batched implementation has to seed its lanes with exactly these words to agree with this one, so the state is part of the public contract rather than an internal detail.
Trait Implementations§
Source§impl Clone for Sha256Compression
impl Clone for Sha256Compression
Source§fn clone(&self) -> Sha256Compression
fn clone(&self) -> Sha256Compression
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl CompressionFunction<Array<u8, <Sha256 as OutputSizeUser>::OutputSize>, 2> for Sha256Compression
impl CompressionFunction<Array<u8, <Sha256 as OutputSizeUser>::OutputSize>, 2> for Sha256Compression
Source§impl Debug for Sha256Compression
impl Debug for Sha256Compression
Auto Trait Implementations§
impl Freeze for Sha256Compression
impl RefUnwindSafe for Sha256Compression
impl Send for Sha256Compression
impl Sync for Sha256Compression
impl Unpin for Sha256Compression
impl UnsafeUnpin for Sha256Compression
impl UnwindSafe for Sha256Compression
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more