summaryrefslogtreecommitdiff
path: root/vm_method.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-06-05 11:42:34 (GMT)
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-06-05 11:42:34 (GMT)
commitb6b76e3a85130dc24dbacd60a82033c780581e9b (patch)
treeceb2a9ef6c63493d267159b4f4d8ab95f8b0de4a /vm_method.c
parent7ac8fe74074a085eb79dfbf501f186fe0af7d1b2 (diff)
* internal.h: move definition of rb_cref_t to method.h.
* eval_intern.h: move definition of rb_scope_visibility_t to method.h. * method.h: change rb_cref_t::scope_visi from VALUE to rb_scope_visibility_t. [Bug #11219] * vm.c (vm_cref_new): accept rb_method_visibility_t directly. * vm_insnhelper.c (rb_vm_rewrite_cref): don't use 0, but METHOD_VISI_UNDEF. * vm_method.c (rb_scope_visibility_set): don't need to use cast. * vm_method.c (rb_scope_module_func_set): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50782 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 e59a161..4813130 100644
--- a/vm_method.c
+++ b/vm_method.c
@@ -959,7 +959,7 @@ rb_scope_module_func_check(void)
void
rb_scope_visibility_set(rb_method_visibility_t visi)
{
- rb_scope_visibility_t *scope_visi = (rb_scope_visibility_t *)&rb_vm_cref()->scope_visi;
+ rb_scope_visibility_t *scope_visi = &rb_vm_cref()->scope_visi;
scope_visi->method_visi = visi;
scope_visi->module_func = FALSE;
}
@@ -967,7 +967,7 @@ rb_scope_visibility_set(rb_method_visibility_t visi)
static void
rb_scope_module_func_set(void)
{
- rb_scope_visibility_t *scope_visi = (rb_scope_visibility_t *)&rb_vm_cref()->scope_visi;
+ rb_scope_visibility_t *scope_visi = &rb_vm_cref()->scope_visi;
scope_visi->method_visi = METHOD_VISI_PRIVATE;
scope_visi->module_func = TRUE;
}