array A_nextFree106 integer A_firstFree930 integer A_maxIndex196 array A_typeId108 integer A_firstFree930 = 0 integer A_maxIndex196 = 0 function initGlobals160() { A_firstFree_930 = 0; A_maxIndex_196 = 0; } function main461() { initGlobals160(); init_test555(); } function config111() { } function init_test555() { local integer b106 local integer clVar701 clVar_701 = alloc_B_test153(); construct_B107(clVar_701); b_106 = clVar_701; dispatch_B_test_B_foo594(b_106, 5); } IS_NATIVE function testSuccess208() { } function foo_test182(integer this775, integer i100) { testSuccess208(); } function A_init158(integer this533) { } function construct_A129(integer this812) { A_init158(this_812); } function B_init165(integer this181) { } function construct_B107(integer this876) { construct_A129(this_876); B_init165(this_876); } function alloc_B_test153() returns integer { local integer this133 if (A_firstFree_930 == 0) { if (A_maxIndex_196 < 32768) { A_maxIndex_196 = (A_maxIndex_196 + 1); this_133 = A_maxIndex_196; A_typeId_108[this_133] = 3; } else { error463("Out of memory: Could not create B_test."); this_133 = 0; }; } else { A_firstFree_930 = (A_firstFree_930 - 1); this_133 = A_nextFree_106[A_firstFree_930]; A_typeId_108[this_133] = 3; }; return this_133; } function error463(string msg860) { $debugPrint509((msg_860 + (" " + #getStackTrace()))); } function dispatch_B_test_B_foo594(integer this175, integer x706) { if (A_typeId_108[this_175] == 0) { if (this_175 == 0) { error463("Nullpointer exception when calling B.foo"); } else { error463("Called B.foo on invalid object."); }; } else { }; foo_test182(this_175, x_706); }