Bug #11182 » alias_affected_by_original_refinement.diff
vm_insnhelper.c | ||
---|---|---|
if (NIL_P(refinement)) {
|
||
goto no_refinement_dispatch;
|
||
}
|
||
me = rb_method_entry(refinement, ci->mid, &defined_class);
|
||
me = rb_method_entry(refinement, ci->me->def->original_id,
|
||
&defined_class);
|
||
if (me) {
|
||
if (ci->call == vm_call_super_method) {
|
||
rb_control_frame_t *top_cfp = current_method_entry(th, cfp);
|
vm_method.c | ||
---|---|---|
{
|
||
rb_method_definition_t *new_def;
|
||
if (me->def && me->def->type == VM_METHOD_TYPE_REFINED)
|
||
if (me->def && me->def->type == VM_METHOD_TYPE_REFINED &&
|
||
me->called_id == me->def->original_id)
|
||
return;
|
||
new_def = ALLOC(rb_method_definition_t);
|
||
... | ... | |
again:
|
||
orig_me = search_method(klass, def, &defined_class);
|
||
if (orig_me && orig_me->def->type == VM_METHOD_TYPE_REFINED) {
|
||
orig_me = rb_resolve_refined_method(Qnil, orig_me, &defined_class);
|
||
}
|
||
if (UNDEFINED_METHOD_ENTRY_P(orig_me) ||
|
||
UNDEFINED_REFINED_METHOD_P(orig_me->def)) {
|