array A_nextFree632 integer A_firstFree210 integer A_maxIndex738 array A_typeId156 integer wurst_stack_depth104 array wurst_stack146 integer A_firstFree210 = 0 integer A_maxIndex738 = 0 integer wurst_stack_depth104 = 0 function initGlobals312() { } function main162() { initGlobals312(); init_test291("when calling init_test in testNoDispatch, line 1"); } function config939() { } function init_test291(string __wurst_stackPos397) { local integer a334 local integer b210 wurst_stack_146[wurst_stack_depth_104] = __wurst_stackPos_397; wurst_stack_depth_104 = (wurst_stack_depth_104 + 1); a_334 = new_A773("when calling new_A in testNoDispatch, line 7"); b_210 = new_B673("when calling new_B in testNoDispatch, line 8"); wurst_stack_146[wurst_stack_depth_104] = "when calling foo in testNoDispatch, line 9"; wurst_stack_depth_104 = (wurst_stack_depth_104 + 1); if (A_typeId_156[a_334] == 0) { if (a_334 == 0) { error427("Nullpointer exception when calling A.foo", "when calling error in testNoDispatch, line 3"); } else { error427("Called A.foo on invalid object.", "when calling error in testNoDispatch, line 3"); }; } else { }; wurst_stack_depth_104 = (wurst_stack_depth_104 - 1); wurst_stack_146[wurst_stack_depth_104] = "when calling foo in testNoDispatch, line 10"; wurst_stack_depth_104 = (wurst_stack_depth_104 + 1); if (A_typeId_156[b_210] == 0) { if (b_210 == 0) { error427("Nullpointer exception when calling B.foo", "when calling error in testNoDispatch, line 5"); } else { error427("Called B.foo on invalid object.", "when calling error in testNoDispatch, line 5"); }; } else { }; wurst_stack_depth_104 = ((wurst_stack_depth_104 - 1) - 1); } function new_A773(string __wurst_stackPos522) returns integer { local integer this183 wurst_stack_146[wurst_stack_depth_104] = __wurst_stackPos_522; wurst_stack_depth_104 = (wurst_stack_depth_104 + 1); wurst_stack_146[wurst_stack_depth_104] = "when calling alloc_A in testNoDispatch, line 2"; wurst_stack_depth_104 = (wurst_stack_depth_104 + 1); if (A_firstFree_210 == 0) { if (A_maxIndex_738 < 32768) { A_maxIndex_738 = (A_maxIndex_738 + 1); this_183 = A_maxIndex_738; A_typeId_156[this_183] = 1; } else { error427("Out of memory: Could not create A.", "when calling error in testNoDispatch, line 2"); this_183 = 0; }; } else { A_firstFree_210 = (A_firstFree_210 - 1); this_183 = A_nextFree_632[A_firstFree_210]; A_typeId_156[this_183] = 1; }; wurst_stack_depth_104 = ((wurst_stack_depth_104 - 1) - 1); return this_183; } function new_B673(string __wurst_stackPos120) returns integer { local integer this743 wurst_stack_146[wurst_stack_depth_104] = __wurst_stackPos_120; wurst_stack_depth_104 = (wurst_stack_depth_104 + 1); wurst_stack_146[wurst_stack_depth_104] = "when calling alloc_B in testNoDispatch, line 4"; wurst_stack_depth_104 = (wurst_stack_depth_104 + 1); if (A_firstFree_210 == 0) { if (A_maxIndex_738 < 32768) { A_maxIndex_738 = (A_maxIndex_738 + 1); this_743 = A_maxIndex_738; A_typeId_156[this_743] = 2; } else { error427("Out of memory: Could not create B.", "when calling error in testNoDispatch, line 4"); this_743 = 0; }; } else { A_firstFree_210 = (A_firstFree_210 - 1); this_743 = A_nextFree_632[A_firstFree_210]; A_typeId_156[this_743] = 2; }; wurst_stack_depth_104 = ((wurst_stack_depth_104 - 1) - 1); return this_743; } function error427(string msg129, string __wurst_stackPos140) { local integer stacktraceIndex505 local integer stacktraceLimit129 wurst_stack_146[wurst_stack_depth_104] = __wurst_stackPos_140; wurst_stack_depth_104 = (wurst_stack_depth_104 + 1); __wurst_stackPos_140 = ""; stacktraceIndex_505 = wurst_stack_depth_104; stacktraceLimit_129 = 0; loop { stacktraceIndex_505 = (stacktraceIndex_505 - 1); stacktraceLimit_129 = (stacktraceLimit_129 + 1); exitwhen ((stacktraceLimit_129 > 20) or (stacktraceIndex_505 < 0)); __wurst_stackPos_140 = (__wurst_stackPos_140 + (" " + wurst_stack_146[stacktraceIndex_505])); }; $debugPrint566((msg_129 + (" " + __wurst_stackPos_140))); wurst_stack_depth_104 = (wurst_stack_depth_104 - 1); }