array C_nextFree491 integer C_firstFree197 integer C_maxIndex195 array C_typeId229 integer C_firstFree197 = 0 integer C_maxIndex195 = 0 function initGlobals312() { C_firstFree_197 = 0; C_maxIndex_195 = 0; } function main214() { initGlobals312(); init_test742(); } function config158() { } function init_test742() { if (dispatch_C_test_C_bar992(new_D570()) == 4) { testSuccess983(); } else { }; } IS_NATIVE function testSuccess983() { } function C_foo787(integer this106) returns integer { return 3; } function C_bar895(integer this158) returns integer { return (dispatch_C_test_C_foo108(this_158) + 1); } function C_init182(integer this115) { } function construct_C865(integer this192) { C_init182(this_192); } function D_init195(integer this599) { } function new_D570() returns integer { local integer this168 this_168 = alloc_D201(); construct_D146(this_168); return this_168; } function construct_D146(integer this137) { construct_C865(this_137); D_init195(this_137); } function error201(string msg250) { $debugPrint459((msg_250 + (" " + #getStackTrace()))); } function alloc_D201() returns integer { local integer this172 if (C_firstFree_197 == 0) { if (C_maxIndex_195 < 32768) { C_maxIndex_195 = (C_maxIndex_195 + 1); this_172 = C_maxIndex_195; C_typeId_229[this_172] = 2; } else { error201("Out of memory: Could not create D."); this_172 = 0; }; } else { C_firstFree_197 = (C_firstFree_197 - 1); this_172 = C_nextFree_491[C_firstFree_197]; C_typeId_229[this_172] = 2; }; return this_172; } function dispatch_C_test_C_foo108(integer this179) returns integer { local integer test_C_foo_result208 if (C_typeId_229[this_179] == 0) { if (this_179 == 0) { error201("Nullpointer exception when calling C.foo"); } else { error201("Called C.foo on invalid object."); }; } else { }; test_C_foo_result_208 = C_foo787(this_179); return test_C_foo_result_208; } function dispatch_C_test_C_bar992(integer this121) returns integer { local integer test_C_bar_result147 if (C_typeId_229[this_121] == 0) { if (this_121 == 0) { error201("Nullpointer exception when calling C.bar"); } else { error201("Called C.bar on invalid object."); }; } else { }; test_C_bar_result_147 = C_bar895(this_121); return test_C_bar_result_147; }