From 0db09b146c3ba3f827009ce17cbf1857a034252d Mon Sep 17 00:00:00 2001 From: Yuichi Nishiwaki Date: Sat, 18 Jan 2014 16:56:20 +0900 Subject: [PATCH] ireps generated by top codegen are not registered to pic->irep. get them marked manually. --- src/gc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gc.c b/src/gc.c index ddab7c87..121e1016 100644 --- a/src/gc.c +++ b/src/gc.c @@ -326,6 +326,9 @@ gc_mark_object(pic_state *pic, struct pic_object *obj) if (proc->env) { gc_mark_object(pic, (struct pic_object *)proc->env); } + if (! proc->cfunc_p) { + gc_mark_object(pic, (struct pic_object *)proc->u.irep); + } break; } case PIC_TT_PORT: {