pub struct Lifetime<'id> { /* private fields */ }Expand description
A fully statically checked ID based on invariant lifetimes and HRTBs.
This is the same technique as used by GhostCell. While theoretically the best option
(being both safe and zero-cost), its infectious nature makes it not very useful in practice.
Implementations§
Trait Implementations§
impl<'id> Copy for Lifetime<'id>
impl<'id> Eq for Lifetime<'id>
impl Id for Lifetime<'_>
impl<'id> StructuralPartialEq for Lifetime<'id>
Auto Trait Implementations§
impl<'id> Freeze for Lifetime<'id>
impl<'id> RefUnwindSafe for Lifetime<'id>
impl<'id> Send for Lifetime<'id>
impl<'id> Sync for Lifetime<'id>
impl<'id> Unpin for Lifetime<'id>
impl<'id> UnwindSafe for Lifetime<'id>
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)