array A_nextFree304 integer A_firstFree183 integer A_maxIndex126 array A_a_0204 array A_a_1399 integer A_firstFree183 = 0 integer A_maxIndex126 = 0 function initGlobals597() { A_firstFree_183 = 0; A_maxIndex_126 = 0; } function main153() { initGlobals597(); init_test104(); } function config936() { } function init_test104() { local integer a472 a_472 = new_A159(); if ((A_a_get212(a_472, 0) == 1) and (A_a_get212(a_472, 1) == 2)) { testSuccess212(); } else { }; } IS_NATIVE function testSuccess212() { } function A_init230(integer this120) { A_a_set149(this_120, 0, 1); A_a_set149(this_120, 1, 2); } function new_A159() returns integer { local integer this904 this_904 = alloc_A808(); construct_A142(this_904); return this_904; } function construct_A142(integer this100) { A_init230(this_100); } function alloc_A808() returns integer { local integer this113 if (A_firstFree_183 == 0) { if (A_maxIndex_126 < 32768) { A_maxIndex_126 = (A_maxIndex_126 + 1); this_113 = A_maxIndex_126; } else { error137("Out of memory: Could not create A."); this_113 = 0; }; } else { A_firstFree_183 = (A_firstFree_183 - 1); this_113 = A_nextFree_304[A_firstFree_183]; }; return this_113; } function error137(string msg163) { $debugPrint144((msg_163 + (" " + #getStackTrace()))); } function A_a_set149(integer instanceId210, integer arrayIndex779, integer value209) { if ((arrayIndex_779 < 0) or (arrayIndex_779 >= 2)) { error137("Index out of Bounds"); } else { if (arrayIndex_779 <= 0) { A_a_0_204[instanceId_210] = value_209; } else { A_a_1_399[instanceId_210] = value_209; }; }; } function A_a_get212(integer index1204, integer index2585) returns integer { local integer returnVal112 if ((index2_585 < 0) or (index2_585 >= 2)) { error137("Index out of Bounds"); } else { if (index2_585 <= 0) { returnVal_112 = A_a_0_204[index1_204]; } else { returnVal_112 = A_a_1_399[index1_204]; }; }; return returnVal_112; }