array A_nextFree222 integer A_firstFree168 integer A_maxIndex164 array A_typeId887 integer A_firstFree168 = 0 integer A_maxIndex164 = 0 function initGlobals107() { } function main116() { initGlobals107(); init_test193(); } function config467() { } function init_test193() { local integer this350 this_350 = new_A429(); if (A_typeId_887[this_350] == 0) { if (this_350 == 0) { error128("Nullpointer exception when calling A.foo"); } else { error128("Called A.foo on invalid object."); }; } else { }; } function new_A429() returns integer { local integer this141 local integer this155 if (A_firstFree_168 == 0) { if (A_maxIndex_164 < 32768) { A_maxIndex_164 = (A_maxIndex_164 + 1); this_155 = A_maxIndex_164; A_typeId_887[this_155] = 1; } else { error128("Out of memory: Could not create A."); this_155 = 0; }; } else { A_firstFree_168 = (A_firstFree_168 - 1); this_155 = A_nextFree_222[A_firstFree_168]; A_typeId_887[this_155] = 1; }; this_141 = this_155; return this_141; } function error128(string msg161) { $debugPrint166((msg_161 + (" " + #getStackTrace()))); }