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

Function wasm_store_new

crates/c-api/src/store.rs:52–60  ·  view source on GitHub ↗
(engine: &wasm_engine_t)

Source from the content-addressed store, hash-verified

50
51#[unsafe(no_mangle)]
52pub extern "C" fn wasm_store_new(engine: &wasm_engine_t) -> Box<wasm_store_t> {
53 let engine = &engine.engine;
54 let store = Store::new(engine, ());
55 Box::new(wasm_store_t {
56 store: WasmStoreRef {
57 store: Arc::new(UnsafeCell::new(store)),
58 },
59 })
60}
61
62// Store-related type aliases for `wasmtime.h` APIs. Not for use with `wasm.h`
63// APIs!

Callers 2

runFunction · 0.85
mainFunction · 0.85

Calls 1

newFunction · 0.50

Tested by

no test coverage detected