| 486 | } |
| 487 | |
| 488 | txSlot* fxFindKey(txMachine* the) |
| 489 | { |
| 490 | #if mxKeysGarbageCollection |
| 491 | txBoolean once = 1; |
| 492 | #endif |
| 493 | txID id; |
| 494 | txSlot* result; |
| 495 | more: |
| 496 | id = the->keyIndex; |
| 497 | if (id < the->keyCount) { |
| 498 | result = fxNewSlot(the); |
| 499 | result->ID = id; |
| 500 | the->keyArray[id - the->keyOffset] = result; |
| 501 | the->keyIndex++; |
| 502 | return result; |
| 503 | } |
| 504 | #if mxKeysGarbageCollection |
| 505 | again: |
| 506 | result = the->keyholeList; |
| 507 | if (result) { |
| 508 | the->keyholeCount--; |
| 509 | the->keyholeList = result->next; |
| 510 | result->next = C_NULL; |
| 511 | return result; |
| 512 | } |
| 513 | if (once) { |
| 514 | fxCollect(the, XS_COLLECT_KEYS_FLAG | XS_ORGANIC_FLAG); |
| 515 | once = 0; |
| 516 | goto again; |
| 517 | } |
| 518 | #endif |
| 519 | else { |
| 520 | fxGrowKeys(the, 1); |
| 521 | goto more; |
| 522 | } |
| 523 | return C_NULL; |
| 524 | } |
| 525 | |
| 526 | void fxFree(txMachine* the) |
| 527 | { |
no test coverage detected