MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / wasm_global_get

Function wasm_global_get

crates/c-api/src/global.rs:68–74  ·  view source on GitHub ↗
(g: &mut wasm_global_t, out: &mut MaybeUninit<wasm_val_t>)

Source from the content-addressed store, hash-verified

66
67#[unsafe(no_mangle)]
68pub unsafe extern "C" fn wasm_global_get(g: &mut wasm_global_t, out: &mut MaybeUninit<wasm_val_t>) {
69 let global = g.global();
70 crate::initialize(
71 out,
72 wasm_val_t::from_val(global.get(g.ext.store.context_mut())),
73 );
74}
75
76#[unsafe(no_mangle)]
77pub unsafe extern "C" fn wasm_global_set(g: &mut wasm_global_t, val: &wasm_val_t) {

Callers

nothing calls this directly

Calls 4

globalMethod · 0.80
context_mutMethod · 0.80
initializeFunction · 0.70
getMethod · 0.45

Tested by

no test coverage detected