array C_nextFree407 integer C_firstFree497 integer C_maxIndex700 array C_typeId325 array C_i580 integer C_firstFree497 = 0 integer C_maxIndex700 = 0 function initGlobals137() { C_firstFree_497 = 0; C_maxIndex_700 = 0; } function main192() { initGlobals137(); init_test897(); } function config883() { } function init_test897() { if (dispatch_D_test_D_foo117(new_D103()) == 6) { testSuccess868(); } else { }; } IS_NATIVE function testSuccess868() { } function C_init498(integer this174) { C_i_580[this_174] = 5; } function construct_C327(integer this615) { C_init498(this_615); } function D_foo209(integer this133) returns integer { return (C_i_580[this_133] + 1); } function D_init963(integer this105) { } function new_D103() returns integer { local integer this183 this_183 = alloc_D261(); construct_D189(this_183); return this_183; } function construct_D189(integer this730) { construct_C327(this_730); D_init963(this_730); } function error660(string msg129) { $debugPrint692((msg_129 + (" " + #getStackTrace()))); } function alloc_D261() returns integer { local integer this176 if (C_firstFree_497 == 0) { if (C_maxIndex_700 < 32768) { C_maxIndex_700 = (C_maxIndex_700 + 1); this_176 = C_maxIndex_700; C_typeId_325[this_176] = 2; } else { error660("Out of memory: Could not create D."); this_176 = 0; }; } else { C_firstFree_497 = (C_firstFree_497 - 1); this_176 = C_nextFree_407[C_firstFree_497]; C_typeId_325[this_176] = 2; }; return this_176; } function dispatch_D_test_D_foo117(integer this410) returns integer { local integer test_D_foo_result109 if (C_typeId_325[this_410] == 0) { if (this_410 == 0) { error660("Nullpointer exception when calling D.foo"); } else { error660("Called D.foo on invalid object."); }; } else { }; test_D_foo_result_109 = D_foo209(this_410); return test_D_foo_result_109; }