pub enum HeapType<'a> {
Func,
Extern,
Any,
Eq,
Data,
Array,
I31,
Index(Index<'a>),
}
Expand description
A heap type for a reference type
Variants
Func
An untyped function reference: funcref. This is part of the reference types proposal.
Extern
A reference to any host value: externref. This is part of the reference types proposal.
Any
A reference to any reference value: anyref. This is part of the GC proposal.
Eq
A reference that has an identity that can be compared: eqref. This is part of the GC proposal.
Data
A reference to a GC object. This is part of the GC proposal.
Array
A reference to a GC array. This is part of the GC proposal.
I31
An unboxed 31-bit integer: i31ref. This may be going away if there is no common supertype of all reference types. Part of the GC proposal.
Index(Index<'a>)
A reference to a function, struct, or array: ref T. This is part of the GC proposal.
Trait Implementations
sourceimpl<'a> Peek for HeapType<'a>
impl<'a> Peek for HeapType<'a>
impl<'a> Copy for HeapType<'a>
impl<'a> Eq for HeapType<'a>
impl<'a> StructuralEq for HeapType<'a>
impl<'a> StructuralPartialEq for HeapType<'a>
Auto Trait Implementations
impl<'a> RefUnwindSafe for HeapType<'a>
impl<'a> Send for HeapType<'a>
impl<'a> Sync for HeapType<'a>
impl<'a> Unpin for HeapType<'a>
impl<'a> UnwindSafe for HeapType<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
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.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more