Struct wasmer::wasm_c_api::value::wasm_val_vec_t [−][src]
#[repr(C)]pub struct wasm_val_vec_t {
pub size: usize,
pub data: *mut wasm_val_t,
}
Expand description
Represents a vector of wasm_val_t
.
Read the documentation of wasm_val_t
to see more concrete examples.
Example
void example(wasm_val_t x, wasm_val_t y) {
// Create a vector of 2 `wasm_val_t`.
wasm_val_t items[2] = {x, y};
wasm_val_vec_t vector;
wasm_val_vec_new(&vector, 2, items);
// Check that it contains 2 items.
assert(vector.size == 2);
// Free it.
wasm_val_vec_delete(&vector);
}
memset(&foo, 0, sizeof(foo));
foo;
}), ({ wasm_val_t foo;
memset(&foo, 0, sizeof(foo));
foo;
})); return 0; }
Fields
size: usize
data: *mut wasm_val_t
Implementations
pub fn as_slice(&self) -> &[wasm_val_t]ⓘ
pub fn as_uninit_slice(&mut self) -> &mut [MaybeUninit<wasm_val_t>]ⓘ
Trait Implementations
Performs the conversion.
Auto Trait Implementations
impl RefUnwindSafe for wasm_val_vec_t
impl !Send for wasm_val_vec_t
impl !Sync for wasm_val_vec_t
impl Unpin for wasm_val_vec_t
impl UnwindSafe for wasm_val_vec_t
Blanket Implementations
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
pub fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
pub fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
Mutably borrows from an owned value. Read more
pub fn deserialize(
&self,
deserializer: &mut D
) -> Result<With<T, W>, <D as Fallible>::Error>
pub fn deserialize(
&self,
deserializer: &mut D
) -> Result<With<T, W>, <D as Fallible>::Error>
Deserializes using the given deserializer
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more