Struct wasmtime_environ::wasm::Global [−][src]
pub struct Global { pub wasm_ty: WasmType, pub ty: Type, pub mutability: bool, pub initializer: GlobalInit, }
Expand description
A WebAssembly global.
Note that we record both the original Wasm type and the Cranelift IR type
used to represent it. This is because multiple different kinds of Wasm types
might be represented with the same Cranelift IR type. For example, both a
Wasm i64
and a funcref
might be represented with a Cranelift i64
on
64-bit architectures, and when GC is not required for func refs.
Fields
wasm_ty: WasmType
The Wasm type of the value stored in the global.
ty: Type
The Cranelift IR type of the value stored in the global.
mutability: bool
A flag indicating whether the value may change at runtime.
initializer: GlobalInit
The source of the initial value.
Trait Implementations
pub fn deserialize<__D>(
__deserializer: __D
) -> Result<Global, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
[src]
pub fn deserialize<__D>(
__deserializer: __D
) -> Result<Global, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
[src]Deserialize this value from the given Serde deserializer. Read more
pub fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
[src]
pub fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
[src]Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for Global
impl UnwindSafe for Global
Blanket Implementations
Mutably borrows from an owned value. Read more
Compare self to key
and return true
if they are equal.