#[repr(C, align(8))]pub struct Word { /* private fields */ }
Expand description
8 bytes, aligned to an 8-byte boundary.
Internally, capnproto-rust allocates message buffers using this type, to guarantee alignment.
Implementations§
Source§impl Word
impl Word
Sourcepub fn allocate_zeroed_vec(length: usize) -> Vec<Self>
pub fn allocate_zeroed_vec(length: usize) -> Vec<Self>
Allocates a vec of length
words, all set to zero.
pub fn words_to_bytes(words: &[Self]) -> &[u8] ⓘ
pub fn words_to_bytes_mut(words: &mut [Self]) -> &mut [u8] ⓘ
Trait Implementations§
impl Copy for Word
impl Eq for Word
impl StructuralPartialEq for Word
Auto Trait Implementations§
impl Freeze for Word
impl RefUnwindSafe for Word
impl Send for Word
impl Sync for Word
impl Unpin for Word
impl UnwindSafe for Word
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