void simulation::run() { //go throught timesteps shouldstop = time > MAXTIME || nstep > MAXSTEP; while (!shouldstop) { //do stuff before timestep starts before_start(); //do the start of the timestep gsph.start(); //do stuff before the middle of the timestep before_middle(); //do the middle of the timestep gsph.middle(); //do stuffbefore the end of the timestep before_end(); //do the end of the timestep gsph.end(); } }
void expression(TVariable *ret_var, Tins_list *act_ins_list) { #ifdef DEBUG_MODE before_start(); #endif switch (its_function()) { case not_function: infix_2_postfix(); generate_code(ret_var, act_ins_list); break; case external_function: generate_external_function(ret_var, act_ins_list); break; case internal_function: generate_internal_function(ret_var, act_ins_list); } #ifdef DEBUG_MODE printf("expr: --END--\n"); #endif }