array SimpleFunc_nextFree621 integer SimpleFunc_firstFree164 integer SimpleFunc_maxIndex116 array SimpleFunc_typeId102 integer SimpleFunc_firstFree164 = 0 integer SimpleFunc_maxIndex116 = 0 function initGlobals159() { } function main572() { initGlobals159(); init_test166(); } function config161() { } function init_test166() { local integer f194 local integer clVar136 local integer g172 local integer this183 if (SimpleFunc_firstFree_164 == 0) { if (SimpleFunc_maxIndex_116 < 32768) { SimpleFunc_maxIndex_116 = (SimpleFunc_maxIndex_116 + 1); this_183 = SimpleFunc_maxIndex_116; SimpleFunc_typeId_102[this_183] = 2; } else { error119("Out of memory: Could not create SimpleFunc_test."); this_183 = 0; }; } else { SimpleFunc_firstFree_164 = (SimpleFunc_firstFree_164 - 1); this_183 = SimpleFunc_nextFree_621[SimpleFunc_firstFree_164]; SimpleFunc_typeId_102[this_183] = 2; }; clVar_136 = this_183; f_194 = clVar_136; g_172 = new_Test204(); if ((dispatch_SimpleFunc_test_SimpleFunc_apply213(f_194, 3, 4) == 7) and (dispatch_SimpleFunc_test_SimpleFunc_apply213(g_172, 3, 4) == 12)) { testSuccess183(); } else { }; } IS_NATIVE function testSuccess183() { } function new_Test204() returns integer { local integer this159 local integer this129 if (SimpleFunc_firstFree_164 == 0) { if (SimpleFunc_maxIndex_116 < 32768) { SimpleFunc_maxIndex_116 = (SimpleFunc_maxIndex_116 + 1); this_129 = SimpleFunc_maxIndex_116; SimpleFunc_typeId_102[this_129] = 3; } else { error119("Out of memory: Could not create Test."); this_129 = 0; }; } else { SimpleFunc_firstFree_164 = (SimpleFunc_firstFree_164 - 1); this_129 = SimpleFunc_nextFree_621[SimpleFunc_firstFree_164]; SimpleFunc_typeId_102[this_129] = 3; }; this_159 = this_129; return this_159; } function error119(string msg191) { $debugPrint120((msg_191 + (" " + #getStackTrace()))); } function dispatch_SimpleFunc_test_SimpleFunc_apply213(integer this186, integer x296, integer y136) returns integer { local integer test_SimpleFunc_apply_result106 local integer x967 local integer y200 local integer x144 local integer y818 if (SimpleFunc_typeId_102[this_186] == 0) { if (this_186 == 0) { error119("Nullpointer exception when calling SimpleFunc.apply"); } else { error119("Called SimpleFunc.apply on invalid object."); }; } else { }; if (SimpleFunc_typeId_102[this_186] <= 2) { x_967 = x_296; y_200 = y_136; test_SimpleFunc_apply_result_106 = (x_967 + y_200); } else { x_144 = x_296; y_818 = y_136; test_SimpleFunc_apply_result_106 = (x_144 * y_818); }; return test_SimpleFunc_apply_result_106; }