pub struct SystemDestinations;Expand description
The default allocator: one host allocation per buffer at the declared alignment.
§Examples
use hurray_io::stream::{Destination, DestinationAlloc, DestinationRequest, SystemDestinations};
let mut dest = SystemDestinations
.allocate(DestinationRequest { index: 0, byte_size: 64, alignment: 64 })?;
assert_eq!(dest.as_mut_slice().len(), 64);
assert_eq!(dest.as_mut_slice().as_ptr() as usize % 64, 0);Trait Implementations§
Source§impl Clone for SystemDestinations
impl Clone for SystemDestinations
Source§fn clone(&self) -> SystemDestinations
fn clone(&self) -> SystemDestinations
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 moreimpl Copy for SystemDestinations
Source§impl Debug for SystemDestinations
impl Debug for SystemDestinations
Source§impl Default for SystemDestinations
impl Default for SystemDestinations
Source§fn default() -> SystemDestinations
fn default() -> SystemDestinations
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for SystemDestinations
impl RefUnwindSafe for SystemDestinations
impl Send for SystemDestinations
impl Sync for SystemDestinations
impl Unpin for SystemDestinations
impl UnsafeUnpin for SystemDestinations
impl UnwindSafe for SystemDestinations
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