#[repr(align(64))]pub struct Align64<T>(pub T);
Expand description
Align to 64 bytes
Tuple Fields§
§0: T
Implementations§
Source§impl<T> Align64<T>
impl<T> Align64<T>
Sourcepub const unsafe fn new_unchecked(input: &T) -> &Self
pub const unsafe fn new_unchecked(input: &T) -> &Self
Perform a reference cast to an Align64<Block<R>>
without checking the alignment.
§Safety
This function is unsafe because it does not check the alignment of the input pointer.
Sourcepub fn new(input: &T) -> &Self
pub fn new(input: &T) -> &Self
Perform a reference cast to an Align64<Block<R>>
.
§Panics
Panics if the input pointer is not aligned to 64 bytes.
Sourcepub const unsafe fn new_mut_unchecked(input: &mut T) -> &mut Self
pub const unsafe fn new_mut_unchecked(input: &mut T) -> &mut Self
Perform a mutable reference cast to an Align64<Block<R>>
without checking the alignment.
§Safety
This function is unsafe because it does not check the alignment of the input pointer.
Sourcepub fn new_mut(input: &mut T) -> &mut Self
pub fn new_mut(input: &mut T) -> &mut Self
Perform a mutable reference cast to an Align64<Block<R>>
.
§Panics
Panics if the input pointer is not aligned to 64 bytes.
Trait Implementations§
Source§impl<'a, R: ArrayLength, B: BlockType> ScryptBlockMixInput<'a, B> for &'a Align64<Block<R>>
impl<'a, R: ArrayLength, B: BlockType> ScryptBlockMixInput<'a, B> for &'a Align64<Block<R>>
Source§impl<'a, R: ArrayLength, B: BlockType> ScryptBlockMixOutput<'a, R, B> for &'a mut Align64<Block<R>>
impl<'a, R: ArrayLength, B: BlockType> ScryptBlockMixOutput<'a, R, B> for &'a mut Align64<Block<R>>
impl<T: Copy> Copy for Align64<T>
impl<T: Eq> Eq for Align64<T>
impl<T> StructuralPartialEq for Align64<T>
Auto Trait Implementations§
impl<T> Freeze for Align64<T>where
T: Freeze,
impl<T> RefUnwindSafe for Align64<T>where
T: RefUnwindSafe,
impl<T> Send for Align64<T>where
T: Send,
impl<T> Sync for Align64<T>where
T: Sync,
impl<T> Unpin for Align64<T>where
T: Unpin,
impl<T> UnwindSafe for Align64<T>where
T: UnwindSafe,
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