pub struct GlobalVar(/* private fields */);
Expand description
Entity handle for a GlobalVarDecl
(a global variable).
Trait Implementations§
source§impl Entity for GlobalVar
impl Entity for GlobalVar
const CHUNK_SIZE: u32 = 65_536u32
type Def = GlobalVarDecl
fn from_non_zero_u32(i: NonZeroU32) -> Self
fn to_non_zero_u32(self) -> NonZeroU32
fn cx_entity_alloc(cx: &Context) -> &EntityAlloc<Self>
const CHUNK_MASK: u32 = _
fn to_chunk_start_and_intra_chunk_idx(self) -> (Self, usize)
impl Copy for GlobalVar
impl Eq for GlobalVar
impl StructuralPartialEq for GlobalVar
Auto Trait Implementations§
impl Freeze for GlobalVar
impl RefUnwindSafe for GlobalVar
impl Send for GlobalVar
impl Sync for GlobalVar
impl Unpin for GlobalVar
impl UnwindSafe for GlobalVar
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<E, V> EntityOrientedMapKey<V> for Ewhere
E: Entity,
impl<E, V> EntityOrientedMapKey<V> for Ewhere
E: Entity,
source§type DenseValueSlots = Option<V>
type DenseValueSlots = Option<V>
A type holding enough different
Option<V>
slots, for all possible
values of Self
, for a given Self::Entity
value contained inside.fn to_entity(key: E) -> E
fn get_dense_value_slot(_: E, slot: &Option<V>) -> &Option<V>
fn get_dense_value_slot_mut(_: E, slot: &mut Option<V>) -> &mut Option<V>
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more