array C_nextFree538 integer C_firstFree141 integer C_maxIndex622 array C_typeId750 array SimpleFunc_nextFree855 integer SimpleFunc_firstFree690 integer SimpleFunc_maxIndex123 array SimpleFunc_typeId976 array C_y869 array this742 integer C_firstFree141 = 0 integer C_maxIndex622 = 0 integer SimpleFunc_firstFree690 = 0 integer SimpleFunc_maxIndex123 = 0 function initGlobals160() { C_firstFree_141 = 0; C_maxIndex_622 = 0; SimpleFunc_firstFree_690 = 0; SimpleFunc_maxIndex_123 = 0; } function main192() { initGlobals160(); init_test114(); } function config202() { } function init_test114() { local integer c734 new_C161(); c_734 = new_C161(); C_y_869[c_734] = 4; dispatch_C_test_C_foo488(c_734); } IS_NATIVE function testSuccess199() { } function C_foo100(integer this276) { local integer clVar158 local integer temp107 temp_107 = this_276; clVar_158 = alloc_SimpleFunc_bar_C_test159(); this_742[clVar_158] = this_276; dispatch_C_test_C_bar206(temp_107, clVar_158); } function C_x707(integer this304) returns integer { return 3; } function C_bar415(integer this173, integer f298) { if (dispatch_SimpleFunc_test_SimpleFunc_apply321(f_298) == 7) { testSuccess199(); } else { }; } function C_init194(integer this190) { } function new_C161() returns integer { local integer this174 this_174 = alloc_C637(); construct_C117(this_174); return this_174; } function construct_C117(integer this214) { C_init194(this_214); } function apply_bar_C_test529(integer this107) returns integer { return (dispatch_C_test_C_x949(this_742[this_107]) + C_y_869[this_742[this_107]]); } function alloc_C637() returns integer { local integer this101 if (C_firstFree_141 == 0) { if (C_maxIndex_622 < 32768) { C_maxIndex_622 = (C_maxIndex_622 + 1); this_101 = C_maxIndex_622; C_typeId_750[this_101] = 1; } else { error201("Out of memory: Could not create C."); this_101 = 0; }; } else { C_firstFree_141 = (C_firstFree_141 - 1); this_101 = C_nextFree_538[C_firstFree_141]; C_typeId_750[this_101] = 1; }; return this_101; } function error201(string msg809) { $debugPrint103((msg_809 + (" " + #getStackTrace()))); } function alloc_SimpleFunc_bar_C_test159() returns integer { local integer this335 if (SimpleFunc_firstFree_690 == 0) { if (SimpleFunc_maxIndex_123 < 32768) { SimpleFunc_maxIndex_123 = (SimpleFunc_maxIndex_123 + 1); this_335 = SimpleFunc_maxIndex_123; SimpleFunc_typeId_976[this_335] = 3; } else { error201("Out of memory: Could not create SimpleFunc_bar_C_test."); this_335 = 0; }; } else { SimpleFunc_firstFree_690 = (SimpleFunc_firstFree_690 - 1); this_335 = SimpleFunc_nextFree_855[SimpleFunc_firstFree_690]; SimpleFunc_typeId_976[this_335] = 3; }; return this_335; } function dispatch_C_test_C_foo488(integer this194) { if (C_typeId_750[this_194] == 0) { if (this_194 == 0) { error201("Nullpointer exception when calling C.foo"); } else { error201("Called C.foo on invalid object."); }; } else { }; C_foo100(this_194); } function dispatch_C_test_C_bar206(integer this938, integer f205) { if (C_typeId_750[this_938] == 0) { if (this_938 == 0) { error201("Nullpointer exception when calling C.bar"); } else { error201("Called C.bar on invalid object."); }; } else { }; C_bar415(this_938, f_205); } function dispatch_C_test_C_x949(integer this128) returns integer { local integer test_C_x_result565 if (C_typeId_750[this_128] == 0) { if (this_128 == 0) { error201("Nullpointer exception when calling C.x"); } else { error201("Called C.x on invalid object."); }; } else { }; test_C_x_result_565 = C_x707(this_128); return test_C_x_result_565; } function dispatch_SimpleFunc_test_SimpleFunc_apply321(integer this949) returns integer { local integer test_SimpleFunc_apply_result111 if (SimpleFunc_typeId_976[this_949] == 0) { if (this_949 == 0) { error201("Nullpointer exception when calling SimpleFunc.apply"); } else { error201("Called SimpleFunc.apply on invalid object."); }; } else { }; test_SimpleFunc_apply_result_111 = apply_bar_C_test529(this_949); return test_SimpleFunc_apply_result_111; }