aboutsummaryrefslogtreecommitdiffstats
path: root/eval_intern.h
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-28 10:01:54 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-28 10:01:54 +0000
commite09dfa64f574fd6b49e65a3d092a1afdcc4d9d32 (patch)
treedf3d94237a6d12d099e235ba62bb743549b5b1b4 /eval_intern.h
parent0abb6b9418a05eb35638251464d842d41ca84bff (diff)
downloadruby-e09dfa64f574fd6b49e65a3d092a1afdcc4d9d32.tar.gz
move fields from `th` to `ec`.
* vm_core.h: move rb_thread_t::passed_block_handler to rb_execution_context_t::passed_block_handler. Also move rb_thread_t::passed_bmethod_me to rb_execution_context_t::passed_bmethod_me. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60503 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'eval_intern.h')
-rw-r--r--eval_intern.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/eval_intern.h b/eval_intern.h
index ed085848b0..1569bfc01a 100644
--- a/eval_intern.h
+++ b/eval_intern.h
@@ -5,23 +5,23 @@
#include "vm_core.h"
static inline void
-vm_passed_block_handler_set(rb_thread_t *th, VALUE block_handler)
+vm_passed_block_handler_set(rb_execution_context_t *ec, VALUE block_handler)
{
vm_block_handler_verify(block_handler);
- th->passed_block_handler = block_handler;
+ ec->passed_block_handler = block_handler;
}
static inline void
-pass_passed_block_handler(rb_thread_t *th)
+pass_passed_block_handler(rb_execution_context_t *ec)
{
- VALUE block_handler = rb_vm_frame_block_handler(th->ec->cfp);
+ VALUE block_handler = rb_vm_frame_block_handler(ec->cfp);
vm_block_handler_verify(block_handler);
- vm_passed_block_handler_set(th, block_handler);
- VM_ENV_FLAGS_SET(th->ec->cfp->ep, VM_FRAME_FLAG_PASSED);
+ vm_passed_block_handler_set(ec, block_handler);
+ VM_ENV_FLAGS_SET(ec->cfp->ep, VM_FRAME_FLAG_PASSED);
}
-#define PASS_PASSED_BLOCK_HANDLER_TH(th) pass_passed_block_handler(th)
-#define PASS_PASSED_BLOCK_HANDLER() pass_passed_block_handler(GET_THREAD())
+#define PASS_PASSED_BLOCK_HANDLER_EC(ec) pass_passed_block_handler(ec)
+#define PASS_PASSED_BLOCK_HANDLER() pass_passed_block_handler(GET_EC())
#ifdef HAVE_STDLIB_H
#include <stdlib.h>