Remove invariant condition
The `while` loop condition dereferences `cfp` and no `break` there, `cfp` cannot be NULL just after the loop.
This commit is contained in:
parent
b69bbf588a
commit
7998dcdedc
5
vm.c
5
vm.c
@ -1750,13 +1750,8 @@ rb_vm_svar_lep(const rb_execution_context_t *ec, const rb_control_frame_t *cfp)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cfp) {
|
|
||||||
return (VALUE *)VM_CF_LEP(cfp);
|
return (VALUE *)VM_CF_LEP(cfp);
|
||||||
}
|
}
|
||||||
else {
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static VALUE
|
static VALUE
|
||||||
vm_cfp_svar_get(const rb_execution_context_t *ec, rb_control_frame_t *cfp, VALUE key)
|
vm_cfp_svar_get(const rb_execution_context_t *ec, rb_control_frame_t *cfp, VALUE key)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user