[][src]Struct capnp::Word

#[repr(C)]
pub struct Word { /* fields omitted */ }

Eight bytes of memory with opaque interior. Use capnp_word!() to construct one of these.

This type is used to ensure that the data of a message is properly aligned.

Methods

impl Word
[src]

Does this, but faster: ::std::iter::repeat(Word(0)).take(length).collect()

Converts a byte slice into a Word slice. Unsafe due to possible alignment issues. Only call this if you know that either

  1. bytes.to_ptr() falls on an eight-byte boundary, or
  2. your processor is okay with unaligned reads.

Converts a mutable byte slice into a mutable Word slice. Unsafe due to possible alignment issues. Only call this if you know that either

  1. bytes.to_ptr() falls on an eight-byte boundary, or
  2. your processor is okay with unaligned reads and writes

Trait Implementations

impl Clone for Word
[src]

Performs copy-assignment from source. Read more

impl Copy for Word
[src]

impl Eq for Word
[src]

impl PartialEq<Word> for Word
[src]

impl Debug for Word
[src]

Auto Trait Implementations

impl Send for Word

impl Sync for Word

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> BorrowMut for T where
    T: ?Sized
[src]