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

Function get_export_func

example/global.c:18–24  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

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

Callers 1

mainFunction · 0.70

Calls 1

wasm_extern_as_funcFunction · 0.85

Tested by

no test coverage detected