array A_nextFree129 integer A_firstFree979 integer A_maxIndex103 array A_typeId162 integer A_firstFree979 = 0 integer A_maxIndex103 = 0 function initGlobals210() { } function main403() { initGlobals210(); init_test158(); } function config170() { } function init_test158() { if (dispatch_A_test_A_foo191(new_B177()) == 8) { testSuccess122(); } else { }; } IS_NATIVE function testSuccess122() { } function A_foo206(integer this108) returns integer { return 7; } function A_init225(integer this211) { } function construct_A138(integer this831) { A_init225(this_831); } function B_foo158(integer this161) returns integer { return 8; } function B_init135(integer this356) { } function new_B177() returns integer { local integer this102 this_102 = alloc_B217(); construct_B784(this_102); return this_102; } function construct_B784(integer this172) { construct_A138(this_172); B_init135(this_172); } function error110(string msg137) { $debugPrint165((msg_137 + (" " + #getStackTrace()))); } function alloc_B217() returns integer { local integer this665 if (A_firstFree_979 == 0) { if (A_maxIndex_103 < 32768) { A_maxIndex_103 = (A_maxIndex_103 + 1); this_665 = A_maxIndex_103; A_typeId_162[this_665] = 2; } else { error110("Out of memory: Could not create B."); this_665 = 0; }; } else { A_firstFree_979 = (A_firstFree_979 - 1); this_665 = A_nextFree_129[A_firstFree_979]; A_typeId_162[this_665] = 2; }; return this_665; } function dispatch_A_test_A_foo191(integer this116) returns integer { if (A_typeId_162[this_116] == 0) { if (this_116 == 0) { error110("Nullpointer exception when calling A.foo"); } else { error110("Called A.foo on invalid object."); }; } else { }; if (A_typeId_162[this_116] <= 1) { this_116 = A_foo206(this_116); } else { this_116 = B_foo158(this_116); }; return this_116; }