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

Function fxReadAtom

xs/sources/xsSnapshot.c:1343–1349  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1341}
1342
1343void fxReadAtom(txMachine* the, txSnapshot* snapshot, Atom* atom, txString type)
1344{
1345 txString check = (txString)&(atom->atomType);
1346 mxThrowIf((*snapshot->read)(snapshot->stream, atom, sizeof(Atom)));
1347 atom->atomSize = ntohl(atom->atomSize) - 8;
1348 mxAssert((check[0] == type[0]) && (check[1] == type[1]) && (check[2] == type[2]) && (check[3] == type[3]), "snapshot: invalid atom %s\n", type);
1349}
1350
1351void fxReadCode(txMachine* the, txSnapshot* snapshot, txByte* data, txSize size)
1352{

Callers 2

fxReadSnapshotFunction · 0.85
fxUseSnapshotFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected