array A_nextFree242 integer A_firstFree254 integer A_maxIndex167 array A_typeId133 integer C_firstFree108 integer C_maxIndex663 integer wurst_stack_depth121 array wurst_stack123 integer A_firstFree254 = 0 integer A_maxIndex167 = 0 integer C_firstFree108 = 0 integer C_maxIndex663 = 0 integer wurst_stack_depth121 = 0 function initGlobals134() { } function main631() { initGlobals134(); init_Test798("when calling init_Test in genericsSubstitute1, line 1"); } function config110() { } function init_Test798(string __wurst_stackPos206) { local integer b354 wurst_stack_123[wurst_stack_depth_121] = __wurst_stackPos_206; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); b_354 = new_B211("when calling new_B in genericsSubstitute1, line 8"); wurst_stack_123[wurst_stack_depth_121] = "when calling new_C in genericsSubstitute1, line 9"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); wurst_stack_123[wurst_stack_depth_121] = "when calling alloc_C in genericsSubstitute1, line 6"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); if (C_firstFree_108 == 0) { if (C_maxIndex_663 < 32768) { C_maxIndex_663 = (C_maxIndex_663 + 1); } else { error536("Out of memory: Could not create C.", "when calling error in genericsSubstitute1, line 6"); }; } else { C_firstFree_108 = (C_firstFree_108 - 1); }; wurst_stack_depth_121 = ((wurst_stack_depth_121 - 1) - 1); wurst_stack_123[wurst_stack_depth_121] = "when calling bla in genericsSubstitute1, line 9"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); if (A_typeId_133[b_354] == 0) { if (b_354 == 0) { error536("Nullpointer exception when calling A.bla", "when calling error in genericsSubstitute1, line 4"); } else { error536("Called A.bla on invalid object.", "when calling error in genericsSubstitute1, line 4"); }; } else { }; wurst_stack_depth_121 = ((wurst_stack_depth_121 - 1) - 1); } function new_B211(string __wurst_stackPos186) returns integer { local integer this923 wurst_stack_123[wurst_stack_depth_121] = __wurst_stackPos_186; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); wurst_stack_123[wurst_stack_depth_121] = "when calling alloc_B in genericsSubstitute1, line 5"; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); if (A_firstFree_254 == 0) { if (A_maxIndex_167 < 32768) { A_maxIndex_167 = (A_maxIndex_167 + 1); this_923 = A_maxIndex_167; A_typeId_133[this_923] = 2; } else { error536("Out of memory: Could not create B.", "when calling error in genericsSubstitute1, line 5"); this_923 = 0; }; } else { A_firstFree_254 = (A_firstFree_254 - 1); this_923 = A_nextFree_242[A_firstFree_254]; A_typeId_133[this_923] = 2; }; wurst_stack_depth_121 = ((wurst_stack_depth_121 - 1) - 1); return this_923; } function error536(string msg930, string __wurst_stackPos210) { local integer stacktraceIndex122 local integer stacktraceLimit151 wurst_stack_123[wurst_stack_depth_121] = __wurst_stackPos_210; wurst_stack_depth_121 = (wurst_stack_depth_121 + 1); __wurst_stackPos_210 = ""; stacktraceIndex_122 = wurst_stack_depth_121; stacktraceLimit_151 = 0; loop { stacktraceIndex_122 = (stacktraceIndex_122 - 1); stacktraceLimit_151 = (stacktraceLimit_151 + 1); exitwhen ((stacktraceLimit_151 > 20) or (stacktraceIndex_122 < 0)); __wurst_stackPos_210 = (__wurst_stackPos_210 + (" " + wurst_stack_123[stacktraceIndex_122])); }; $debugPrint157((msg_930 + (" " + __wurst_stackPos_210))); wurst_stack_depth_121 = (wurst_stack_depth_121 - 1); }