s/env.numcv/env.num_val/g
This commit is contained in:
parent
a926c54be3
commit
411395995c
|
@ -4,7 +4,7 @@
|
|||
struct pic_env {
|
||||
PIC_OBJECT_HEADER
|
||||
pic_value *values;
|
||||
int numcv;
|
||||
int num_val;
|
||||
struct pic_env *up;
|
||||
};
|
||||
|
||||
|
|
2
src/gc.c
2
src/gc.c
|
@ -163,7 +163,7 @@ gc_mark_object(pic_state *pic, struct pic_object *obj)
|
|||
struct pic_env *env = (struct pic_env *)obj;
|
||||
int i;
|
||||
|
||||
for (i = 0; i < env->numcv; ++i) {
|
||||
for (i = 0; i < env->num_val; ++i) {
|
||||
gc_mark(pic, env->values[i]);
|
||||
}
|
||||
gc_mark_object(pic, (struct pic_object *)env->up);
|
||||
|
|
4
src/vm.c
4
src/vm.c
|
@ -280,8 +280,8 @@ pic_run(pic_state *pic, struct pic_proc *proc, pic_value args)
|
|||
struct pic_env *env;
|
||||
|
||||
env = (struct pic_env *)pic_obj_alloc(pic, sizeof(struct pic_env), PIC_TT_ENV);
|
||||
env->numcv = pic->irep[pc->u.i]->argc;
|
||||
env->values = (pic_value *)pic_alloc(pic, sizeof(pic_value) * env->numcv);
|
||||
env->num_val = pic->irep[pc->u.i]->argc;
|
||||
env->values = (pic_value *)pic_alloc(pic, sizeof(pic_value) * env->num_val);
|
||||
env->up = pic_proc_ptr(*pic->ci->fp)->env;
|
||||
|
||||
proc = pic_proc_new(pic, pic->irep[pc->u.i], env);
|
||||
|
|
Loading…
Reference in New Issue