volatilemachine_uint_tcurrently_in_except_block=0;// 0 or 1, to detect nested exceptions
mp_exc_stack*volatileexc_sp=*exc_sp_in_out;// stack grows up, exc_sp points to top of stack
volatilemachine_uint_tcurrently_in_except_block=(int)*exc_sp_in_out&1;// 0 or 1, to detect nested exceptions
mp_exc_stack*volatileexc_sp=(void*)((int)*exc_sp_in_out&~1);// stack grows up, exc_sp points to top of stack
constbyte*volatilesave_ip=ip;// this is so we can access ip in the exception handler without making ip volatile (which means the compiler can't keep it in a register in the main loop)
// outer exception handling loop
for(;;){
if(nlr_push(&nlr)==0){
// If we have exception to inject, now that we finish setting up
// execution context, raise it. This works as if RAISE_VARARGS