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

Function deserialize_and_instantiate

tests/all/module_serialize.rs:10–13  ·  view source on GitHub ↗
(store: &mut Store<()>, buffer: &[u8])

Source from the content-addressed store, hash-verified

8}
9
10unsafe fn deserialize_and_instantiate(store: &mut Store<()>, buffer: &[u8]) -> Result<Instance> {
11 let module = unsafe { Module::deserialize(store.engine(), buffer)? };
12 Ok(Instance::new(store, &module, &[])?)
13}
14
15#[test]
16fn test_version_mismatch() -> Result<()> {

Callers 2

Calls 4

OkFunction · 0.85
deserializeFunction · 0.50
newFunction · 0.50
engineMethod · 0.45

Tested by 2