MCPcopy Create free account
hub / github.com/WebAssembly/wasm-c-api / get_export_func

Function get_export_func

example/memory.c:19–25  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17}
18
19wasm_func_t* get_export_func(const wasm_extern_vec_t* exports, size_t i) {
20 if (exports->size <= i || !wasm_extern_as_func(exports->data[i])) {
21 printf("> Error accessing function export %zu!\n", i);
22 exit(1);
23 }
24 return wasm_extern_as_func(exports->data[i]);
25}
26
27
28void check(bool success) {

Callers 1

mainFunction · 0.70

Calls 1

wasm_extern_as_funcFunction · 0.85

Tested by

no test coverage detected