array B_nextFree129 integer B_firstFree730 integer B_maxIndex123 array B_typeId198 integer B_firstFree730 = 0 integer B_maxIndex123 = 0 function initGlobals522() { } function main181() { initGlobals522(); init_A357(); } function config830() { } function init_A357() { local integer clVar372 local integer b2132 local integer clVar306 local integer this170 local integer b872 local integer this669 if (B_firstFree_730 == 0) { if (B_maxIndex_123 < 32768) { B_maxIndex_123 = (B_maxIndex_123 + 1); this_170 = B_maxIndex_123; B_typeId_198[this_170] = 3; } else { error104("Out of memory: Could not create B_bar_A."); this_170 = 0; }; } else { B_firstFree_730 = (B_firstFree_730 - 1); this_170 = B_nextFree_129[B_firstFree_730]; B_typeId_198[this_170] = 3; }; clVar_372 = this_170; b_872 = clVar_372; dispatch_B_destroyB141(b_872); if (B_firstFree_730 == 0) { if (B_maxIndex_123 < 32768) { B_maxIndex_123 = (B_maxIndex_123 + 1); this_669 = B_maxIndex_123; B_typeId_198[this_669] = 2; } else { error104("Out of memory: Could not create B_A."); this_669 = 0; }; } else { B_firstFree_730 = (B_firstFree_730 - 1); this_669 = B_nextFree_129[B_firstFree_730]; B_typeId_198[this_669] = 2; }; clVar_306 = this_669; b2_132 = clVar_306; if ((b2_132 castTo integer) == 1) { testSuccess126(); } else { }; } IS_NATIVE function testSuccess126() { } function error104(string msg337) { $debugPrint132((msg_337 + (" " + #getStackTrace()))); } function dispatch_B_destroyB141(integer this288) { local integer this232 local integer obj178 if (B_typeId_198[this_288] == 0) { if (this_288 == 0) { error104("Nullpointer exception when calling B.B"); } else { error104("Called B.B on invalid object."); }; } else { }; this_232 = this_288; obj_178 = this_232; if (B_typeId_198[obj_178] == 0) { error104("Double free: object of type B"); } else { B_nextFree_129[B_firstFree_730] = obj_178; B_firstFree_730 = (B_firstFree_730 + 1); B_typeId_198[obj_178] = 0; }; }