array A_nextFree152 integer A_firstFree866 integer A_maxIndex200 array Func_nextFree136 integer Func_firstFree170 integer Func_maxIndex144 array Func_typeId560 array A_f139 integer A_firstFree866 = 0 integer A_maxIndex200 = 0 integer Func_firstFree170 = 0 integer Func_maxIndex144 = 0 function initGlobals148() { A_firstFree_866 = 0; A_maxIndex_200 = 0; Func_firstFree_170 = 0; Func_maxIndex_144 = 0; } function main183() { initGlobals148(); init_test230(); } function config922() { } function init_test230() { local integer a201 a_201 = new_A742(); if (dispatch_Func_test_Func_apply213(A_f_139[a_201], 3) == 4) { testSuccess409(); } else { }; } IS_NATIVE function testSuccess409() { } function A_init132(integer this161) { local integer clVar792 clVar_792 = alloc_Func_A_test294(); A_f_139[this_161] = clVar_792; } function new_A742() returns integer { local integer this281 this_281 = alloc_A732(); construct_A998(this_281); return this_281; } function construct_A998(integer this190) { A_init132(this_190); } function apply_A_test371(integer this166, integer x212) returns integer { return (x_212 + 1); } function alloc_A732() returns integer { local integer this543 if (A_firstFree_866 == 0) { if (A_maxIndex_200 < 32768) { A_maxIndex_200 = (A_maxIndex_200 + 1); this_543 = A_maxIndex_200; } else { error544("Out of memory: Could not create A."); this_543 = 0; }; } else { A_firstFree_866 = (A_firstFree_866 - 1); this_543 = A_nextFree_152[A_firstFree_866]; }; return this_543; } function error544(string msg157) { $debugPrint630((msg_157 + (" " + #getStackTrace()))); } function alloc_Func_A_test294() returns integer { local integer this164 if (Func_firstFree_170 == 0) { if (Func_maxIndex_144 < 32768) { Func_maxIndex_144 = (Func_maxIndex_144 + 1); this_164 = Func_maxIndex_144; Func_typeId_560[this_164] = 3; } else { error544("Out of memory: Could not create Func_A_test."); this_164 = 0; }; } else { Func_firstFree_170 = (Func_firstFree_170 - 1); this_164 = Func_nextFree_136[Func_firstFree_170]; Func_typeId_560[this_164] = 3; }; return this_164; } function dispatch_Func_test_Func_apply213(integer this148, integer x196) returns integer { local integer test_Func_apply_result202 if (Func_typeId_560[this_148] == 0) { if (this_148 == 0) { error544("Nullpointer exception when calling Func.apply"); } else { error544("Called Func.apply on invalid object."); }; } else { }; test_Func_apply_result_202 = apply_A_test371(this_148, x_196); return test_Func_apply_result_202; }