array SimpleFunc_nextFree185 integer SimpleFunc_firstFree498 integer SimpleFunc_maxIndex667 array SimpleFunc_typeId312 array main315 integer SimpleFunc_firstFree498 = 0 integer SimpleFunc_maxIndex667 = 0 function initGlobals252() { SimpleFunc_firstFree_498 = 0; SimpleFunc_maxIndex_667 = 0; } function main148() { initGlobals252(); init_test995(); } function config124() { } function init_test995() { local integer main185 local integer f431 local integer clVar939 main_185 = 4; clVar_939 = alloc_SimpleFunc_test150(); main_315[clVar_939] = main_185; f_431 = clVar_939; if (dispatch_SimpleFunc_test_SimpleFunc_apply197(f_431, 3) == 7) { testSuccess368(); } else { }; } IS_NATIVE function testSuccess368() { } function apply_test568(integer this207, integer x952) returns integer { return (x_952 + main_315[this_207]); } function alloc_SimpleFunc_test150() returns integer { local integer this946 if (SimpleFunc_firstFree_498 == 0) { if (SimpleFunc_maxIndex_667 < 32768) { SimpleFunc_maxIndex_667 = (SimpleFunc_maxIndex_667 + 1); this_946 = SimpleFunc_maxIndex_667; SimpleFunc_typeId_312[this_946] = 2; } else { error157("Out of memory: Could not create SimpleFunc_test."); this_946 = 0; }; } else { SimpleFunc_firstFree_498 = (SimpleFunc_firstFree_498 - 1); this_946 = SimpleFunc_nextFree_185[SimpleFunc_firstFree_498]; SimpleFunc_typeId_312[this_946] = 2; }; return this_946; } function error157(string msg293) { $debugPrint247((msg_293 + (" " + #getStackTrace()))); } function dispatch_SimpleFunc_test_SimpleFunc_apply197(integer this355, integer x208) returns integer { local integer test_SimpleFunc_apply_result430 if (SimpleFunc_typeId_312[this_355] == 0) { if (this_355 == 0) { error157("Nullpointer exception when calling SimpleFunc.apply"); } else { error157("Called SimpleFunc.apply on invalid object."); }; } else { }; test_SimpleFunc_apply_result_430 = apply_test568(this_355, x_208); return test_SimpleFunc_apply_result_430; }