array A_nextFree685 integer A_firstFree145 integer A_maxIndex259 array C_nextFree102 integer C_firstFree357 integer C_maxIndex293 array C_typeId197 integer A_firstFree145 = 0 integer A_maxIndex259 = 0 integer C_firstFree357 = 0 integer C_maxIndex293 = 0 function initGlobals152() { } function main663() { initGlobals152(); init_Test683(); } function config166() { } function init_Test683() { local integer this143 this_143 = new_C530(); new_A239(); if (C_typeId_197[this_143] == 0) { if (this_143 == 0) { error133("Nullpointer exception when calling C.foo"); } else { error133("Called C.foo on invalid object."); }; } else { }; this_143 = new_C530(); if (C_typeId_197[this_143] == 0) { if (this_143 == 0) { error133("Nullpointer exception when calling C.foo"); } else { error133("Called C.foo on invalid object."); }; } else { }; testSuccess180(); } IS_NATIVE function testSuccess180() { } function new_A239() returns integer { local integer this210 if (A_firstFree_145 == 0) { if (A_maxIndex_259 < 32768) { A_maxIndex_259 = (A_maxIndex_259 + 1); this_210 = A_maxIndex_259; } else { error133("Out of memory: Could not create A."); this_210 = 0; }; } else { A_firstFree_145 = (A_firstFree_145 - 1); this_210 = A_nextFree_685[A_firstFree_145]; }; return this_210; } function new_C530() returns integer { local integer this362 if (C_firstFree_357 == 0) { if (C_maxIndex_293 < 32768) { C_maxIndex_293 = (C_maxIndex_293 + 1); this_362 = C_maxIndex_293; C_typeId_197[this_362] = 2; } else { error133("Out of memory: Could not create C."); this_362 = 0; }; } else { C_firstFree_357 = (C_firstFree_357 - 1); this_362 = C_nextFree_102[C_firstFree_357]; C_typeId_197[this_362] = 2; }; return this_362; } function error133(string msg151) { $debugPrint134((msg_151 + (" " + #getStackTrace()))); }