Struct zerogc::AssumeNotTraced
source · [−]#[repr(transparent)]pub struct AssumeNotTraced<T>(_);
Expand description
A wrapper type that assumes its contents don’t need to be traced
Implementations
sourceimpl<T> AssumeNotTraced<T>
impl<T> AssumeNotTraced<T>
sourcepub unsafe fn new(value: T) -> Self
pub unsafe fn new(value: T) -> Self
Assume the specified value doesn’t need to be traced
Safety
Undefined behavior if the value contains anything that need to be traced by a garbage collector.
sourcepub fn into_inner(self) -> T
pub fn into_inner(self) -> T
Unwrap the inner value of this wrapper
Trait Implementations
sourceimpl<T: Clone> Clone for AssumeNotTraced<T>
impl<T: Clone> Clone for AssumeNotTraced<T>
sourcefn clone(&self) -> AssumeNotTraced<T>
fn clone(&self) -> AssumeNotTraced<T>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<T: Debug> Debug for AssumeNotTraced<T>
impl<T: Debug> Debug for AssumeNotTraced<T>
sourceimpl<T> Deref for AssumeNotTraced<T>
impl<T> Deref for AssumeNotTraced<T>
sourceimpl<T> DerefMut for AssumeNotTraced<T>
impl<T> DerefMut for AssumeNotTraced<T>
sourceimpl<'new_gc, T, Id: CollectorId> GcRebrand<'new_gc, Id> for AssumeNotTraced<T>
impl<'new_gc, T, Id: CollectorId> GcRebrand<'new_gc, Id> for AssumeNotTraced<T>
sourceimpl<'gc, T, Id: CollectorId> GcSafe<'gc, Id> for AssumeNotTraced<T>
impl<'gc, T, Id: CollectorId> GcSafe<'gc, Id> for AssumeNotTraced<T>
sourceimpl<T> Trace for AssumeNotTraced<T>
impl<T> Trace for AssumeNotTraced<T>
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<T> TraceImmutable for AssumeNotTraced<T>
impl<T> TraceImmutable for AssumeNotTraced<T>
impl<T: Copy> Copy for AssumeNotTraced<T>
impl<T> NullTrace for AssumeNotTraced<T>
impl<T> TrustedDrop for AssumeNotTraced<T>
Auto Trait Implementations
impl<T> RefUnwindSafe for AssumeNotTraced<T> where
T: RefUnwindSafe,
impl<T> Send for AssumeNotTraced<T> where
T: Send,
impl<T> Sync for AssumeNotTraced<T> where
T: Sync,
impl<T> Unpin for AssumeNotTraced<T> where
T: Unpin,
impl<T> UnwindSafe for AssumeNotTraced<T> where
T: UnwindSafe,
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)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more