array C_nextFree123 integer C_firstFree132 integer C_maxIndex220 array C_typeId382 array SimpleFunc_nextFree124 integer SimpleFunc_firstFree169 integer SimpleFunc_maxIndex200 array SimpleFunc_typeId168 array C_y163 array this154 integer C_firstFree132 = 0 integer C_maxIndex220 = 0 integer SimpleFunc_firstFree169 = 0 integer SimpleFunc_maxIndex200 = 0 function initGlobals186() { } function main771() { local integer c136 local integer this203 initGlobals186(); new_C228(); c_136 = new_C228(); C_y_163[c_136] = 4; this_203 = c_136; if (C_typeId_382[this_203] == 0) { if (this_203 == 0) { error142("Nullpointer exception when calling C.foo"); } else { error142("Called C.foo on invalid object."); }; } else { }; C_foo100(this_203); } function config160() { } IS_NATIVE function testSuccess115() { } function C_foo100(integer this195) { local integer clVar974 local integer temp212 local integer this115 local integer this483 local integer f172 local integer f707 temp_212 = this_195; if (SimpleFunc_firstFree_169 == 0) { if (SimpleFunc_maxIndex_200 < 32768) { SimpleFunc_maxIndex_200 = (SimpleFunc_maxIndex_200 + 1); this_115 = SimpleFunc_maxIndex_200; SimpleFunc_typeId_168[this_115] = 3; } else { error142("Out of memory: Could not create SimpleFunc_bar_C_test."); this_115 = 0; }; } else { SimpleFunc_firstFree_169 = (SimpleFunc_firstFree_169 - 1); this_115 = SimpleFunc_nextFree_124[SimpleFunc_firstFree_169]; SimpleFunc_typeId_168[this_115] = 3; }; clVar_974 = this_115; this_154[clVar_974] = this_195; this_483 = temp_212; f_172 = clVar_974; if (C_typeId_382[this_483] == 0) { if (this_483 == 0) { error142("Nullpointer exception when calling C.bar"); } else { error142("Called C.bar on invalid object."); }; } else { }; f_707 = f_172; if (dispatch_SimpleFunc_test_SimpleFunc_apply155(f_707) == 7) { testSuccess115(); } else { }; } function new_C228() returns integer { local integer this149 local integer this382 if (C_firstFree_132 == 0) { if (C_maxIndex_220 < 32768) { C_maxIndex_220 = (C_maxIndex_220 + 1); this_382 = C_maxIndex_220; C_typeId_382[this_382] = 1; } else { error142("Out of memory: Could not create C."); this_382 = 0; }; } else { C_firstFree_132 = (C_firstFree_132 - 1); this_382 = C_nextFree_123[C_firstFree_132]; C_typeId_382[this_382] = 1; }; this_149 = this_382; return this_149; } function error142(string msg331) { $debugPrint166((msg_331 + (" " + #getStackTrace()))); } function dispatch_SimpleFunc_test_SimpleFunc_apply155(integer this113) returns integer { local integer test_SimpleFunc_apply_result122 local integer this168 local integer this406 local integer test_C_x_result117 if (SimpleFunc_typeId_168[this_113] == 0) { if (this_113 == 0) { error142("Nullpointer exception when calling SimpleFunc.apply"); } else { error142("Called SimpleFunc.apply on invalid object."); }; } else { }; this_168 = this_113; this_406 = this_154[this_168]; if (C_typeId_382[this_406] == 0) { if (this_406 == 0) { error142("Nullpointer exception when calling C.x"); } else { error142("Called C.x on invalid object."); }; } else { }; test_C_x_result_117 = 3; test_SimpleFunc_apply_result_122 = (test_C_x_result_117 + C_y_163[this_154[this_168]]); return test_SimpleFunc_apply_result_122; }