summaryrefslogtreecommitdiff
path: root/vm_method.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-03-08 19:50:37 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-03-08 19:50:37 +0000
commitae166317a4cceeaa195760f675f89a4afec0feee (patch)
tree2acb49ed9eb1037637b7e0b0f0ea98991a27a4ad /vm_method.c
parentb6d5ce7975667cc32d7d86a992d5206627e5ff73 (diff)
* internal.h: define CREF accessor macros.
* CREF_CLASS(cref) * CREF_NEXT(cref) * CREF_VISI(cref) * CREF_VISI_SET(cref, v) * CREF_REFINEMENTS(cref) * CREF_PUSHED_BY_EVAL(cref) * CREF_PUSHED_BY_EVAL_SET(cref) * CREF_OMOD_SHARED(cref) * CREF_OMOD_SHARED_SET(cref) * CREF_OMOD_SHARED_UNSET(cref) This is process to change CREF data type from NODE. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49894 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_method.c')
-rw-r--r--vm_method.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/vm_method.c b/vm_method.c
index d5fe524..48c518f 100644
--- a/vm_method.c
+++ b/vm_method.c
@@ -479,7 +479,7 @@ rb_add_method0(VALUE klass, ID mid, rb_method_type_t type, void *opts, rb_method
private_cref = vm_cref_new_toplevel(GET_THREAD()); /* TODO: CREF should be shared with other methods */
if (cref) COPY_CREF(private_cref, cref);
- private_cref->nd_visi = NOEX_PUBLIC;
+ CREF_VISI_SET(private_cref, NOEX_PUBLIC);
RB_OBJ_WRITE(klass, &def->body.iseq_body.cref, private_cref);
break;
}
@@ -744,7 +744,7 @@ rb_method_entry_with_refinements(VALUE klass, ID id,
if (me && me->def->type == VM_METHOD_TYPE_REFINED) {
NODE *cref = rb_vm_cref();
- VALUE refinements = cref ? cref->nd_refinements : Qnil;
+ VALUE refinements = cref ? CREF_REFINEMENTS(cref) : Qnil;
me = rb_resolve_refined_method(refinements, me, &defined_class);
}