MCPcopy Create free account
hub / github.com/WasmEdge/WasmEdge / WasmEdge_LoaderCreate

Function WasmEdge_LoaderCreate

lib/api/wasmedge.cpp:2002–2016  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2000// >>>>>>>> WasmEdge loader functions >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
2001
2002WASMEDGE_CAPI_EXPORT WasmEdge_LoaderContext *
2003WasmEdge_LoaderCreate(const WasmEdge_ConfigureContext *ConfCxt) noexcept {
2004 try {
2005 if (ConfCxt) {
2006 return toLoaderCxt(new WasmEdge::Loader::Loader(
2007 ConfCxt->Conf, &WasmEdge::Executor::Executor::Intrinsics));
2008 } else {
2009 return toLoaderCxt(new WasmEdge::Loader::Loader(
2010 WasmEdge::Configure(), &WasmEdge::Executor::Executor::Intrinsics));
2011 }
2012 } catch (...) {
2013 handleCAPIError();
2014 return nullptr;
2015 }
2016}
2017
2018WASMEDGE_CAPI_EXPORT WasmEdge_Result WasmEdge_LoaderParseFromFile(
2019 WasmEdge_LoaderContext *Cxt, WasmEdge_ASTModuleContext **Module,

Callers 4

TestContextMethod · 0.85
TESTFunction · 0.85
loadModuleFunction · 0.85
TESTFunction · 0.85

Calls 2

ConfigureClass · 0.85
handleCAPIErrorFunction · 0.85

Tested by 4

TestContextMethod · 0.68
TESTFunction · 0.68
loadModuleFunction · 0.68
TESTFunction · 0.68