array C_nextFree179 integer C_firstFree127 integer C_maxIndex211 array C_typeId118 integer C_firstFree127 = 0 integer C_maxIndex211 = 0 function initGlobals183() { C_firstFree_127 = 0; C_maxIndex_211 = 0; } function main145() { initGlobals183(); init_test340(); } function config120() { } function init_test340() { if (dispatch_D_test_D_foo756(new_D343()) == 4) { testSuccess159(); } else { }; } IS_NATIVE function testSuccess159() { } function C_init133(integer this166) { } function construct_C179(integer this774) { C_init133(this_774); } function D_foo251(integer this484) returns integer { return 4; } function D_init234(integer this171) { } function new_D343() returns integer { local integer this127 this_127 = alloc_D214(); construct_D119(this_127); return this_127; } function construct_D119(integer this157) { construct_C179(this_157); D_init234(this_157); } function error181(string msg724) { $debugPrint146((msg_724 + (" " + #getStackTrace()))); } function alloc_D214() returns integer { local integer this166 if (C_firstFree_127 == 0) { if (C_maxIndex_211 < 32768) { C_maxIndex_211 = (C_maxIndex_211 + 1); this_166 = C_maxIndex_211; C_typeId_118[this_166] = 2; } else { error181("Out of memory: Could not create D."); this_166 = 0; }; } else { C_firstFree_127 = (C_firstFree_127 - 1); this_166 = C_nextFree_179[C_firstFree_127]; C_typeId_118[this_166] = 2; }; return this_166; } function dispatch_D_test_D_foo756(integer this943) returns integer { local integer test_D_foo_result296 if (C_typeId_118[this_943] == 0) { if (this_943 == 0) { error181("Nullpointer exception when calling D.foo"); } else { error181("Called D.foo on invalid object."); }; } else { }; test_D_foo_result_296 = D_foo251(this_943); return test_D_foo_result_296; }