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

Function fxGetCallbackName

xs/tools/xslSlot.c:378–408  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

376}
377
378txString fxGetCallbackName(txMachine* the, txCallback which)
379{
380 txLinker* linker = xsGetContext(the);
381 if (!which)
382 return "NULL";
383 {
384 txLinkerCallback* linkerCallback = fxGetLinkerCallbackByAddress(linker, which);
385 if (linkerCallback) {
386 if (linkerCallback->flag)
387 return linkerCallback->name;
388 return "fxDeadStrip";
389 }
390 }
391 {
392 txLinkerScript* linkerScript = linker->firstScript;
393 while (linkerScript) {
394 txInteger count = linkerScript->hostsCount;
395 if (count) {
396 txCallbackName* address = &(linkerScript->callbackNames[0]);
397 while (count) {
398 if (address->callback == which)
399 return address->name;
400 address++;
401 count--;
402 }
403 }
404 linkerScript = linkerScript->nextScript;
405 }
406 }
407 return "OOPS";
408}
409
410txString fxGetCodeName(txMachine* the, txByte* which)
411{

Callers 2

fxPrintBuildersFunction · 0.85
fxPrintSlotFunction · 0.85

Calls 1

Tested by

no test coverage detected