integer test_x467 array A_nextFree116 integer A_firstFree102 integer A_maxIndex958 array A_typeId646 integer test_x467 = 2 integer A_firstFree102 = 0 integer A_maxIndex958 = 0 function initGlobals384() { A_firstFree_102 = 0; A_maxIndex_958 = 0; } function main141() { initGlobals384(); init_test210(); } function config197() { } function init_test210() { local integer a958 test_x_467 = 2; a_958 = new_B235(); dispatch_A_test_A_foo159(a_958); if (test_x_467 == 5) { testSuccess207(); } else { }; } IS_NATIVE function testSuccess207() { } function A_foo134(integer this185) { test_x_467 = 4; } function A_init907(integer this109) { } function construct_A141(integer this601) { A_init907(this_601); } function B_foo127(integer this929) { test_x_467 = 5; } function B_init149(integer this103) { } function new_B235() returns integer { local integer this151 this_151 = alloc_B184(); construct_B450(this_151); return this_151; } function construct_B450(integer this222) { construct_A141(this_222); B_init149(this_222); } function C_foo650(integer this124) { test_x_467 = 6; } function error207(string msg772) { $debugPrint194((msg_772 + (" " + #getStackTrace()))); } function alloc_B184() returns integer { local integer this821 if (A_firstFree_102 == 0) { if (A_maxIndex_958 < 32768) { A_maxIndex_958 = (A_maxIndex_958 + 1); this_821 = A_maxIndex_958; A_typeId_646[this_821] = 2; } else { error207("Out of memory: Could not create B."); this_821 = 0; }; } else { A_firstFree_102 = (A_firstFree_102 - 1); this_821 = A_nextFree_116[A_firstFree_102]; A_typeId_646[this_821] = 2; }; return this_821; } function dispatch_A_test_A_foo159(integer this119) { if (A_typeId_646[this_119] == 0) { if (this_119 == 0) { error207("Nullpointer exception when calling A.foo"); } else { error207("Called A.foo on invalid object."); }; } else { }; if (A_typeId_646[this_119] <= 2) { if (A_typeId_646[this_119] <= 1) { A_foo134(this_119); } else { B_foo127(this_119); }; } else { C_foo650(this_119); }; }