array I_nextFree864 integer I_firstFree811 integer I_maxIndex120 array I_typeId251 integer I_firstFree811 = 0 integer I_maxIndex120 = 0 function initGlobals214() { } function main204() { initGlobals214(); init_test226(); } function config118() { } function init_test226() { local integer c1391 local integer c2816 c1_391 = new_C175(); c2_816 = new_D406(); if ((dispatch_B_test1_B_foo193(c1_391) == 2) and (dispatch_B_test1_B_foo193(c2_816) == 2)) { testSuccess615(); } else { }; } IS_NATIVE function testSuccess615() { } function B_foo212(integer this561) returns integer { return 2; } function B_init116(integer this190) { } function construct_B670(integer this208) { B_init116(this_208); } function C_init485(integer this201) { } function new_C175() returns integer { local integer this116 this_116 = alloc_C271(); construct_C814(this_116); return this_116; } function construct_C814(integer this107) { construct_B670(this_107); C_init485(this_107); } function D_init348(integer this293) { } function new_D406() returns integer { local integer this211 this_211 = alloc_D205(); construct_D163(this_211); return this_211; } function construct_D163(integer this197) { construct_C814(this_197); D_init348(this_197); } function error799(string msg805) { $debugPrint952((msg_805 + (" " + #getStackTrace()))); } function alloc_C271() returns integer { local integer this946 if (I_firstFree_811 == 0) { if (I_maxIndex_120 < 32768) { I_maxIndex_120 = (I_maxIndex_120 + 1); this_946 = I_maxIndex_120; I_typeId_251[this_946] = 3; } else { error799("Out of memory: Could not create C."); this_946 = 0; }; } else { I_firstFree_811 = (I_firstFree_811 - 1); this_946 = I_nextFree_864[I_firstFree_811]; I_typeId_251[this_946] = 3; }; return this_946; } function alloc_D205() returns integer { local integer this132 if (I_firstFree_811 == 0) { if (I_maxIndex_120 < 32768) { I_maxIndex_120 = (I_maxIndex_120 + 1); this_132 = I_maxIndex_120; I_typeId_251[this_132] = 4; } else { error799("Out of memory: Could not create D."); this_132 = 0; }; } else { I_firstFree_811 = (I_firstFree_811 - 1); this_132 = I_nextFree_864[I_firstFree_811]; I_typeId_251[this_132] = 4; }; return this_132; } function dispatch_B_test1_B_foo193(integer this131) returns integer { if (I_typeId_251[this_131] == 0) { if (this_131 == 0) { error799("Nullpointer exception when calling B.foo"); } else { error799("Called B.foo on invalid object."); }; } else { }; return B_foo212(this_131); }