pub struct Table<T, const N: usize> { /* private fields */ }
Expand description
A contiguous memory block.
§Example:
// Make sure that the type used in the table implements the Default trait.
#[derive(Default)]
struct Entity {
x: f32,
y: f32,
}
struct Data {
// Memory reserved for (in this specific example) 512 entities.
entities: Table<Entity, 512>
}
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<T, const N: usize> Freeze for Table<T, N>where
T: Freeze,
impl<T, const N: usize> RefUnwindSafe for Table<T, N>where
T: RefUnwindSafe,
impl<T, const N: usize> Send for Table<T, N>where
T: Send,
impl<T, const N: usize> Sync for Table<T, N>where
T: Sync,
impl<T, const N: usize> Unpin for Table<T, N>where
T: Unpin,
impl<T, const N: usize> UnwindSafe for Table<T, N>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