[bugfix] pic_load_point should restore pic->cc

This commit is contained in:
Yuichi Nishiwaki 2015-07-06 14:18:49 +09:00
parent f210efd066
commit 5e6f6f85f4
2 changed files with 1 additions and 3 deletions

View File

@ -79,6 +79,7 @@ pic_load_point(pic_state *pic, struct pic_cont *cont)
pic->arena_idx = cont->arena_idx;
pic->ip = cont->ip;
pic->ptable = cont->ptable;
pic->cc = cont->prev;
}
static pic_value
@ -140,8 +141,6 @@ pic_callcc(pic_state *pic, struct pic_proc *proc)
pic_save_point(pic, &cont);
if (PIC_SETJMP(pic, cont.jmp)) {
pic->cc = pic->cc->prev;
return pic_values_by_list(pic, cont.results);
}
else {

View File

@ -44,7 +44,6 @@ struct pic_error *pic_make_error(pic_state *, pic_sym *, const char *, pic_list)
} while (0); \
pic->cc = pic->cc->prev; \
} else { \
pic->cc = pic->cc->prev; \
goto label; \
} \
} while (0); \