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

Function get_export_func

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

Source from the content-addressed store, hash-verified

16}
17
18auto get_export_func(const wasm::ownvec<wasm::Extern>& exports, size_t i) -> const wasm::Func* {
19 if (exports.size() <= i || !exports[i]->func()) {
20 std::cout << "> Error accessing function export " << i << "!" << std::endl;
21 exit(1);
22 }
23 return exports[i]->func();
24}
25
26template<class T, class U>
27void check(T actual, U expected) {

Callers 1

runFunction · 0.70

Calls 2

funcMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected