MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / fxGetArchiveCodeName

Function fxGetArchiveCodeName

xs/sources/xsAPI.c:2070–2086  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2068}
2069
2070void* fxGetArchiveCodeName(txMachine* the, void* archive, txInteger index)
2071{
2072 txU4 atomSize;
2073 txU1 *p = fxGetArchiveModules(the, archive, &atomSize), *q;
2074 if (!p)
2075 return NULL;
2076 q = p + atomSize;
2077 while (p < q) {
2078 // PATH
2079 if (!index--)
2080 return (txString)(p + sizeof(Atom));
2081 p += c_read32be(p);
2082 // CODE
2083 p += c_read32be(p);
2084 }
2085 return C_NULL;
2086}
2087
2088static txU1 *fxGetArchiveResources(txMachine *the, void* archive, txU4 *size)
2089{

Callers

nothing calls this directly

Calls 1

fxGetArchiveModulesFunction · 0.85

Tested by

no test coverage detected