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

Method loadExternName

lib/loader/ast/component/component_valtype.cpp:9–20  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7namespace Loader {
8
9Expect<void> Loader::loadExternName(std::string &Name) {
10 // importname' ::= 0x00 len:<u32> in:<importname> => in (if len = |in|)
11 // exportname' ::= 0x00 len:<u32> en:<exportname> => en (if len = |en|)
12
13 // Error messages will be handled in the parent scope.
14 EXPECTED_TRY(auto B, FMgr.readByte());
15 if (B != 0x00) {
16 return Unexpect(ErrCode::Value::MalformedName);
17 }
18 EXPECTED_TRY(Name, FMgr.readName());
19 return {};
20}
21
22Expect<void> Loader::loadType(ComponentValType &Ty) {
23 // valtype ::= i:<typeidx> => i

Callers

nothing calls this directly

Calls 3

UnexpectFunction · 0.85
readNameMethod · 0.80
EXPECTED_TRYFunction · 0.70

Tested by

no test coverage detected