pub enum WasmHeapType {
Show 13 variants
Extern,
NoExtern,
Func,
ConcreteFunc(EngineOrModuleTypeIndex),
NoFunc,
Any,
Eq,
I31,
Array,
ConcreteArray(EngineOrModuleTypeIndex),
Struct,
ConcreteStruct(EngineOrModuleTypeIndex),
None,
}
Expand description
WebAssembly heap type – equivalent of wasmparser
’s HeapType
Variants§
Extern
NoExtern
Func
ConcreteFunc(EngineOrModuleTypeIndex)
NoFunc
Any
Eq
I31
Array
ConcreteArray(EngineOrModuleTypeIndex)
Struct
ConcreteStruct(EngineOrModuleTypeIndex)
None
Implementations§
Source§impl WasmHeapType
impl WasmHeapType
Sourcepub fn is_vmgcref_type(&self) -> bool
pub fn is_vmgcref_type(&self) -> bool
Is this a type that is represented as a VMGcRef
?
Sourcepub fn is_vmgcref_type_and_not_i31(&self) -> bool
pub fn is_vmgcref_type_and_not_i31(&self) -> bool
Is this a type that is represented as a VMGcRef
and is additionally
not an i31
?
That is, is this a a type that actually refers to an object allocated in a GC heap?
Sourcepub fn top(&self) -> WasmHeapTopType
pub fn top(&self) -> WasmHeapTopType
Get this type’s top type.
Trait Implementations§
Source§impl Clone for WasmHeapType
impl Clone for WasmHeapType
Source§fn clone(&self) -> WasmHeapType
fn clone(&self) -> WasmHeapType
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for WasmHeapType
impl Debug for WasmHeapType
Source§impl<'de> Deserialize<'de> for WasmHeapType
impl<'de> Deserialize<'de> for WasmHeapType
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<WasmHeapType, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<WasmHeapType, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for WasmHeapType
impl Display for WasmHeapType
Source§impl From<WasmHeapTopType> for WasmHeapType
impl From<WasmHeapTopType> for WasmHeapType
Source§fn from(value: WasmHeapTopType) -> WasmHeapType
fn from(value: WasmHeapTopType) -> WasmHeapType
Converts to this type from the input type.
Source§impl Hash for WasmHeapType
impl Hash for WasmHeapType
Source§impl PartialEq for WasmHeapType
impl PartialEq for WasmHeapType
Source§impl Serialize for WasmHeapType
impl Serialize for WasmHeapType
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Source§impl TypeTrace for WasmHeapType
impl TypeTrace for WasmHeapType
Source§fn trace_mut<F, E>(&mut self, func: &mut F) -> Result<(), E>
fn trace_mut<F, E>(&mut self, func: &mut F) -> Result<(), E>
Visit each edge, mutably. Read more
Source§fn trace_engine_indices<F, E>(&self, func: &mut F) -> Result<(), E>
fn trace_engine_indices<F, E>(&self, func: &mut F) -> Result<(), E>
Trace all
VMSharedTypeIndex
edges, ignoring other edges.Source§fn canonicalize_for_runtime_usage<F>(&mut self, module_to_engine: &mut F)
fn canonicalize_for_runtime_usage<F>(&mut self, module_to_engine: &mut F)
Canonicalize
self
by rewriting all type references inside self
from
module-level interned type indices to engine-level interned type
indices. Read moreSource§fn is_canonicalized_for_runtime_usage(&self) -> bool
fn is_canonicalized_for_runtime_usage(&self) -> bool
Is this type canonicalized for runtime usage?
Source§fn canonicalize_for_hash_consing<F>(
&mut self,
rec_group_range: Range<ModuleInternedTypeIndex>,
module_to_engine: &mut F,
)
fn canonicalize_for_hash_consing<F>( &mut self, rec_group_range: Range<ModuleInternedTypeIndex>, module_to_engine: &mut F, )
Canonicalize
self
by rewriting all type references inside self
from
module-level interned type indices to either engine-level interned type
indices or recgroup-relative indices. Read moreSource§fn is_canonicalized_for_hash_consing(&self) -> bool
fn is_canonicalized_for_hash_consing(&self) -> bool
Is this type canonicalized for hash consing?
impl Copy for WasmHeapType
impl Eq for WasmHeapType
impl StructuralPartialEq for WasmHeapType
Auto Trait Implementations§
impl Freeze for WasmHeapType
impl RefUnwindSafe for WasmHeapType
impl Send for WasmHeapType
impl Sync for WasmHeapType
impl Unpin for WasmHeapType
impl UnwindSafe for WasmHeapType
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<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<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§impl<T> IntoAnyhow for T
impl<T> IntoAnyhow for T
Source§fn into_anyhow(self) -> Error
fn into_anyhow(self) -> Error
Converts
self
into an anyhow::Error
.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