summaryrefslogtreecommitdiff
path: root/vm.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-07-14 17:59:03 (GMT)
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-07-14 17:59:03 (GMT)
commit994460c4db639d098ec72ca54b3442f5ea05336f (patch)
tree07c1f5969ade76aaae767bcc660ead39da4e7091 /vm.c
parente07dad00ee37173a990cc8d4f147963d7f57a28c (diff)
* vm_core.h, vm.c: remove rb_proc_t::envval because we can know it via
rb_proc_t::block::ep. rb_vm_proc_envval(const rb_proc_t *proc) returns an Env object which the Proc object use. * proc.c: catch up this fix. * vm_dump.c (rb_vmdebug_proc_dump_raw): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51246 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm.c')
-rw-r--r--vm.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/vm.c b/vm.c
index db4d6d8..1940c5a 100644
--- a/vm.c
+++ b/vm.c
@@ -679,7 +679,6 @@ rb_proc_create(VALUE klass, const rb_block_t *block,
proc->safe_level = safe_level;
proc->is_from_method = is_from_method;
proc->is_lambda = is_lambda;
- proc->envval = envval;
return procval;
}
@@ -712,6 +711,14 @@ rb_vm_make_proc_lambda(rb_thread_t *th, const rb_block_t *block, VALUE klass, in
return procval;
}
+VALUE
+rb_vm_proc_envval(const rb_proc_t *proc)
+{
+ VALUE envval = VM_ENV_EP_ENVVAL(proc->block.ep);
+ return envval;
+}
+
+
/* Binding */
VALUE