pub struct Unsupported<'gc, T, Id: CollectorId> {
pub marker: PhantomData<Gc<'gc, [T], Id>>,
pub never: Infallible,
}
Fields
marker: PhantomData<Gc<'gc, [T], Id>>
The marker PhantomData
needed to construct this type
never: Infallible
indicates this type should never exist at runtime
Trait Implementations
sourceimpl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> Clone for Unsupported<'gc, T, Id>
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> Clone for Unsupported<'gc, T, Id>
sourceimpl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> Extend<T> for Unsupported<'gc, T, Id>
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> Extend<T> for Unsupported<'gc, T, Id>
sourcefn extend<I: IntoIterator<Item = T>>(&mut self, _iter: I)
fn extend<I: IntoIterator<Item = T>>(&mut self, _iter: I)
Extends a collection with the contents of an iterator. Read more
sourcefn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Extends a collection with exactly one element.
sourcefn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)Reserves capacity in a collection for the given number of additional elements. Read more
sourceimpl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> GcRawVec<'gc, T> for Unsupported<'gc, T, Id>
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> GcRawVec<'gc, T> for Unsupported<'gc, T, Id>
sourceunsafe fn steal_as_array_unchecked(self) -> GcArray<'gc, T, Id>
unsafe fn steal_as_array_unchecked(self) -> GcArray<'gc, T, Id>
Steal ownership of this vector, converting it into a [GcArray]. Read more
sourcefn iter(&self) -> RawVecIter<'gc, T, Self>ⓘNotable traits for RawVecIter<'gc, T, V>impl<'gc, T: GcSafe<'gc, V::Id> + Copy, V: GcRawVec<'gc, T>> Iterator for RawVecIter<'gc, T, V> type Item = T;
where
T: Copy,
fn iter(&self) -> RawVecIter<'gc, T, Self>ⓘNotable traits for RawVecIter<'gc, T, V>impl<'gc, T: GcSafe<'gc, V::Id> + Copy, V: GcRawVec<'gc, T>> Iterator for RawVecIter<'gc, T, V> type Item = T;
where
T: Copy,
Iterate over the elements of the vectors Read more
sourceimpl<'gc, 'new_gc, T: GcSafe<'gc, Id>, Id: CollectorId> GcRebrand<'new_gc, Id> for Unsupported<'gc, T, Id> where
T: GcRebrand<'new_gc, Id>,
T::Branded: Sized,
impl<'gc, 'new_gc, T: GcSafe<'gc, Id>, Id: CollectorId> GcRebrand<'new_gc, Id> for Unsupported<'gc, T, Id> where
T: GcRebrand<'new_gc, Id>,
T::Branded: Sized,
type Branded = Unsupported<'new_gc, T::Branded, Id>
type Branded = Unsupported<'new_gc, T::Branded, Id>
This type with all garbage collected lifetimes
changed to 'new_gc
Read more
sourceimpl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> GcSafe<'gc, Id> for Unsupported<'gc, T, Id>
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> GcSafe<'gc, Id> for Unsupported<'gc, T, Id>
sourceimpl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> IGcVec<'gc, T> for Unsupported<'gc, T, Id>
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> IGcVec<'gc, T> for Unsupported<'gc, T, Id>
type Id = Id
type Id = Id
The id of the collector
sourcefn capacity(&self) -> usize
fn capacity(&self) -> usize
The total amount of space that is available without needing reallocation. Read more
sourcefn with_capacity_in(
capacity: usize,
ctx: &'gc <Id as CollectorId>::Context
) -> Self
fn with_capacity_in(
capacity: usize,
ctx: &'gc <Id as CollectorId>::Context
) -> Self
Allocate a new vector with the specified capacity, using the specified context. Read more
sourcefn reserve_in_place(
&mut self,
additional: usize
) -> Result<(), ReallocFailedError>
fn reserve_in_place(
&mut self,
additional: usize
) -> Result<(), ReallocFailedError>
Attempt to reallocate the vector in-place, without moving the underlying pointer. Read more
sourcefn from_vec(src: Vec<T>, ctx: &'gc <Self::Id as CollectorId>::Context) -> Self
fn from_vec(src: Vec<T>, ctx: &'gc <Self::Id as CollectorId>::Context) -> Self
Copy the specified elements into a new vector, allocating it in the specified context Read more
sourcefn copy_from_slice(
src: &[T],
ctx: &'gc <Self::Id as CollectorId>::Context
) -> Self where
T: Copy,
fn copy_from_slice(
src: &[T],
ctx: &'gc <Self::Id as CollectorId>::Context
) -> Self where
T: Copy,
Copy the specified elements into a new vector, allocating it in the specified context Read more
sourcefn new_in(ctx: &'gc <Self::Id as CollectorId>::Context) -> Self
fn new_in(ctx: &'gc <Self::Id as CollectorId>::Context) -> Self
Allocate a new vector inside the specified context
sourcefn pop(&mut self) -> Option<T>
fn pop(&mut self) -> Option<T>
Pop an element of the end of the vector,
returning None
if empty. Read more
sourcefn swap_remove(&mut self, index: usize) -> T
fn swap_remove(&mut self, index: usize) -> T
Removes an element from the vector and returns it. Read more
sourcefn extend_from_slice(&mut self, src: &[T]) where
T: Copy,
fn extend_from_slice(&mut self, src: &[T]) where
T: Copy,
Extend the vector with elements copied from the specified slice
sourcefn get(&self, idx: usize) -> Option<T> where
T: Copy,
fn get(&self, idx: usize) -> Option<T> where
T: Copy,
Get the item at the specified index,
or None
if it is out of bounds. Read more
sourcefn replace(&mut self, index: usize, val: T) -> T
fn replace(&mut self, index: usize, val: T) -> T
Replace the item at the specified index, returning the old value. Read more
sourceunsafe fn as_mut_ptr(&mut self) -> *mut T
unsafe fn as_mut_ptr(&mut self) -> *mut T
Get a mutable pointer to the vector’s underlying data. Read more
sourceimpl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> Trace for Unsupported<'gc, T, Id> where
T: Trace,
Id: Trace,
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> Trace for Unsupported<'gc, T, Id> where
T: Trace,
Id: Trace,
sourceconst NEEDS_TRACE: bool
const NEEDS_TRACE: bool
Whether this type needs to be traced by the garbage collector. Read more
sourceconst NEEDS_DROP: bool
const NEEDS_DROP: bool
If this type needs a destructor run. Read more
sourceimpl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> TraceImmutable for Unsupported<'gc, T, Id> where
T: TraceImmutable,
Id: TraceImmutable,
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> TraceImmutable for Unsupported<'gc, T, Id> where
T: TraceImmutable,
Id: TraceImmutable,
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> Copy for Unsupported<'gc, T, Id>
impl<'gc, T: GcSafe<'gc, Id>, Id: CollectorId> TrustedDrop for Unsupported<'gc, T, Id> where
T: TrustedDrop,
Id: TrustedDrop,
Auto Trait Implementations
impl<'gc, T, Id> RefUnwindSafe for Unsupported<'gc, T, Id> where
T: RefUnwindSafe,
<Id as CollectorId>::Context: RefUnwindSafe,
impl<'gc, T, Id> Send for Unsupported<'gc, T, Id> where
Id: Sync,
T: GcSafe<Id> + Sync,
impl<'gc, T, Id> Sync for Unsupported<'gc, T, Id> where
Id: Sync,
T: GcSafe<Id> + Sync,
impl<'gc, T, Id> Unpin for Unsupported<'gc, T, Id>
impl<'gc, T, Id> UnwindSafe for Unsupported<'gc, T, Id> where
T: RefUnwindSafe,
<Id as CollectorId>::Context: RefUnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more