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

Function fx_Map_groupBy

xs/sources/xsMapSet.c:335–348  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

333}
334
335void fx_Map_groupBy(txMachine* the)
336{
337 txSlot *instance, *key, *value;
338 mxPush(mxMapPrototype);
339 instance = fxNewMapInstance(the);
340 mxPullSlot(mxResult);
341 fxGroupBy(the, fx_Map_groupByAux);
342 key = instance->next->next->value.list.first;
343 while (key) {
344 value = key->next;
345 fxCacheArray(the, value->value.reference);
346 key = value->next;
347 }
348}
349
350void fx_Map_prototype_clear(txMachine* the)
351{

Callers

nothing calls this directly

Calls 3

fxNewMapInstanceFunction · 0.85
fxGroupByFunction · 0.85
fxCacheArrayFunction · 0.85

Tested by

no test coverage detected