string test_s766 array T_nextFree122 integer T_firstFree188 integer T_maxIndex145 array T_typeId184 integer wurst_stack_depth121 array wurst_stack830 string test_s766 = "" integer T_firstFree188 = 0 integer T_maxIndex145 = 0 integer wurst_stack_depth121 = 0 function initGlobals118() { } function main206() { initGlobals118(); wurst_stack_830[wurst_stack_depth_121] = "when calling init_test in ondestroy_dynamicdispatchFrotty3, line 1"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); test_s_766 = ""; dispatch_T_destroyT156(new_A212("when calling new_A in ondestroy_dynamicdispatchFrotty3, line 15"), "when calling dispatch_T_destroyT in ondestroy_dynamicdispatchFrotty3, line 16"); if (test_s_766 == "C") { testSuccess311(); } else { }; wurst_stack_depth_121 = (wurst_stack_depth_121 - 1); } function config107() { } IS_NATIVE function testSuccess311() { } function new_A212(string __wurst_stackPos209) returns integer { local integer this130 wurst_stack_830[wurst_stack_depth_121] = __wurst_stackPos_209; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); wurst_stack_830[wurst_stack_depth_121] = "when calling alloc_A in ondestroy_dynamicdispatchFrotty3, line 7"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); if (T_firstFree_188 == 0) { if (T_maxIndex_145 < 32768) { T_maxIndex_145 = (T_maxIndex_145 + 1); this_130 = T_maxIndex_145; T_typeId_184[this_130] = 2; } else { error112("Out of memory: Could not create A.", "when calling error in ondestroy_dynamicdispatchFrotty3, line 7"); this_130 = 0; }; } else { T_firstFree_188 = (T_firstFree_188 - 1); this_130 = T_nextFree_122[T_firstFree_188]; T_typeId_184[this_130] = 2; }; wurst_stack_depth_121 = ((wurst_stack_depth_121 - 1) - 1); return this_130; } function error112(string msg155, string __wurst_stackPos595) { local integer stacktraceIndex183 local integer stacktraceLimit102 wurst_stack_830[wurst_stack_depth_121] = __wurst_stackPos_595; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); __wurst_stackPos_595 = ""; stacktraceIndex_183 = wurst_stack_depth_121; stacktraceLimit_102 = 0; loop { stacktraceIndex_183 = (stacktraceIndex_183 - 1); stacktraceLimit_102 = (stacktraceLimit_102 + 1); exitwhen ((stacktraceLimit_102 > 20) or (stacktraceIndex_183 < 0)); __wurst_stackPos_595 = (__wurst_stackPos_595 + (" " + wurst_stack_830[stacktraceIndex_183])); }; $debugPrint123((msg_155 + (" " + __wurst_stackPos_595))); wurst_stack_depth_121 = (wurst_stack_depth_121 - 1); } function dispatch_T_destroyT156(integer this154, string __wurst_stackPos545) { wurst_stack_830[wurst_stack_depth_121] = __wurst_stackPos_545; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); if (T_typeId_184[this_154] == 0) { if (this_154 == 0) { error112("Nullpointer exception when calling T.T", "when calling error in ondestroy_dynamicdispatchFrotty3, line 11"); } else { error112("Called T.T on invalid object.", "when calling error in ondestroy_dynamicdispatchFrotty3, line 11"); }; } else { }; if (T_typeId_184[this_154] <= 3) { if (T_typeId_184[this_154] <= 2) { wurst_stack_830[wurst_stack_depth_121] = "when calling destroyA in ondestroy_dynamicdispatchFrotty3, line 11"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); test_s_766 = (test_s_766 + "C"); wurst_stack_830[wurst_stack_depth_121] = "when calling dealloc_A in ondestroy_dynamicdispatchFrotty3, line 7"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); if (T_typeId_184[this_154] == 0) { error112("Double free: object of type A", "when calling error in ondestroy_dynamicdispatchFrotty3, line 7"); } else { T_nextFree_122[T_firstFree_188] = this_154; T_firstFree_188 = (T_firstFree_188 + 1); T_typeId_184[this_154] = 0; }; wurst_stack_depth_121 = ((wurst_stack_depth_121 - 1) - 1); } else { wurst_stack_830[wurst_stack_depth_121] = "when calling destroyB in ondestroy_dynamicdispatchFrotty3, line 11"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); test_s_766 = ((test_s_766 + "B") + "C"); wurst_stack_830[wurst_stack_depth_121] = "when calling dealloc_B in ondestroy_dynamicdispatchFrotty3, line 9"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); if (T_typeId_184[this_154] == 0) { error112("Double free: object of type B", "when calling error in ondestroy_dynamicdispatchFrotty3, line 8"); } else { T_nextFree_122[T_firstFree_188] = this_154; T_firstFree_188 = (T_firstFree_188 + 1); T_typeId_184[this_154] = 0; }; wurst_stack_depth_121 = ((wurst_stack_depth_121 - 1) - 1); }; } else { wurst_stack_830[wurst_stack_depth_121] = "when calling destroyT in ondestroy_dynamicdispatchFrotty3, line 11"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); wurst_stack_830[wurst_stack_depth_121] = "when calling dealloc_T in ondestroy_dynamicdispatchFrotty3, line 11"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); if (T_typeId_184[this_154] == 0) { error112("Double free: object of type T", "when calling error in ondestroy_dynamicdispatchFrotty3, line 11"); } else { T_nextFree_122[T_firstFree_188] = this_154; T_firstFree_188 = (T_firstFree_188 + 1); T_typeId_184[this_154] = 0; }; wurst_stack_depth_121 = ((wurst_stack_depth_121 - 1) - 1); }; wurst_stack_depth_121 = (wurst_stack_depth_121 - 1); }