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

Function fxStringOwnKeys

xs/sources/xsString.c:523–539  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

521}
522
523void fxStringOwnKeys(txMachine* the, txSlot* instance, txFlag flag, txSlot* keys)
524{
525 txSlot* property = instance->next;
526 if (flag & XS_EACH_NAME_FLAG) {
527 txIndex length = mxStringInstanceLength(instance), index;
528 for (index = 0; index < length; index++)
529 keys = fxQueueKey(the, 0, index, keys);
530 }
531 property = property->next;
532 if (property && (property->kind == XS_ARRAY_KIND)) {
533 keys = fxQueueIndexKeys(the, property, flag, keys);
534 property = property->next;
535 }
536 if (flag & XS_EACH_NAME_FLAG)
537 keys = fxQueueKey(the, mxID(_length), 0, keys);
538 fxQueueIDKeys(the, property, flag, keys);
539}
540
541txSlot* fxStringSetProperty(txMachine* the, txSlot* instance, txID id, txIndex index, txFlag flag)
542{

Callers

nothing calls this directly

Calls 3

fxQueueKeyFunction · 0.85
fxQueueIndexKeysFunction · 0.85
fxQueueIDKeysFunction · 0.85

Tested by

no test coverage detected