array SimpleFunc_nextFree147 integer SimpleFunc_firstFree204 integer SimpleFunc_maxIndex575 array SimpleFunc_typeId204 array y142 integer SimpleFunc_firstFree204 = 0 integer SimpleFunc_maxIndex575 = 0 function initGlobals200() { SimpleFunc_firstFree_204 = 0; SimpleFunc_maxIndex_575 = 0; } function main180() { initGlobals200(); init_test212(); } function config735() { } function init_test212() { test183(4); } function test183(integer y152) { local integer f893 local integer clVar114 clVar_114 = alloc_SimpleFunc_test965(); y_142[clVar_114] = y_152; f_893 = clVar_114; if (dispatch_SimpleFunc_test_SimpleFunc_apply165(f_893, 3) == 7) { testSuccess143(); } else { }; } IS_NATIVE function testSuccess143() { } function apply_test139(integer this202, integer x660) returns integer { return (x_660 + y_142[this_202]); } function alloc_SimpleFunc_test965() returns integer { local integer this604 if (SimpleFunc_firstFree_204 == 0) { if (SimpleFunc_maxIndex_575 < 32768) { SimpleFunc_maxIndex_575 = (SimpleFunc_maxIndex_575 + 1); this_604 = SimpleFunc_maxIndex_575; SimpleFunc_typeId_204[this_604] = 2; } else { error508("Out of memory: Could not create SimpleFunc_test."); this_604 = 0; }; } else { SimpleFunc_firstFree_204 = (SimpleFunc_firstFree_204 - 1); this_604 = SimpleFunc_nextFree_147[SimpleFunc_firstFree_204]; SimpleFunc_typeId_204[this_604] = 2; }; return this_604; } function error508(string msg172) { $debugPrint685((msg_172 + (" " + #getStackTrace()))); } function dispatch_SimpleFunc_test_SimpleFunc_apply165(integer this201, integer x136) returns integer { local integer test_SimpleFunc_apply_result108 if (SimpleFunc_typeId_204[this_201] == 0) { if (this_201 == 0) { error508("Nullpointer exception when calling SimpleFunc.apply"); } else { error508("Called SimpleFunc.apply on invalid object."); }; } else { }; test_SimpleFunc_apply_result_108 = apply_test139(this_201, x_136); return test_SimpleFunc_apply_result_108; }