remove toplevel pic_env that is never used

This commit is contained in:
Yuichi Nishiwaki 2013-11-04 15:30:11 -05:00
parent 70fbe46dc1
commit 76dadc8448
1 changed files with 1 additions and 11 deletions

View File

@ -647,8 +647,6 @@ pic_codegen(pic_state *pic, pic_value obj)
{ {
struct pic_proc *proc; struct pic_proc *proc;
codegen_state *state; codegen_state *state;
struct pic_env *env;
int i;
state = new_codegen_state(pic); state = new_codegen_state(pic);
@ -671,15 +669,7 @@ pic_codegen(pic_state *pic, pic_value obj)
state->irep->code[state->irep->clen].insn = OP_RET; state->irep->code[state->irep->clen].insn = OP_RET;
state->irep->clen++; state->irep->clen++;
env = (struct pic_env *)pic_obj_alloc(pic, sizeof(struct pic_env), PIC_TT_ENV); proc = pic_proc_new(pic, state->irep, NULL);
env->num_val = state->irep->argc + state->irep->localc;
env->values = (pic_value *)pic_alloc(pic, sizeof(pic_value) * env->num_val);
for (i = 0; i < env->num_val; ++i) {
env->values[i] = pic_undef_value();
}
env->up = NULL;
proc = pic_proc_new(pic, state->irep, env);
destroy_codegen_state(pic, state); destroy_codegen_state(pic, state);