aboutsummaryrefslogtreecommitdiffstats
path: root/eval_jump.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-29 15:41:53 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-29 15:41:53 +0000
commit7bcebbff372a7b4d1b521ca90c0cc2b9a09041b3 (patch)
tree264dd8fdab5e51534f4c5acb8182b5caf3532b42 /eval_jump.c
parent14170a60419657330eaa8fed131cfd176af29e8e (diff)
downloadruby-7bcebbff372a7b4d1b521ca90c0cc2b9a09041b3.tar.gz
* eval_jump.c (rb_exec_end_proc): use `GET_EC()`.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60564 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'eval_jump.c')
-rw-r--r--eval_jump.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/eval_jump.c b/eval_jump.c
index 6ae92af23e..c6972bf319 100644
--- a/eval_jump.c
+++ b/eval_jump.c
@@ -115,27 +115,26 @@ rb_exec_end_proc(void)
{
enum ruby_tag_type state;
volatile int safe = rb_safe_level();
- rb_thread_t *th = GET_THREAD();
- volatile VALUE errinfo = th->ec->errinfo;
+ rb_execution_context_t * volatile ec = GET_EC();
+ volatile VALUE errinfo = ec->errinfo;
- EC_PUSH_TAG(th->ec);
+ EC_PUSH_TAG(ec);
if ((state = EXEC_TAG()) == TAG_NONE) {
again:
- exec_end_procs_chain(&ephemeral_end_procs, &th->ec->errinfo);
- exec_end_procs_chain(&end_procs, &th->ec->errinfo);
+ exec_end_procs_chain(&ephemeral_end_procs, &ec->errinfo);
+ exec_end_procs_chain(&end_procs, &ec->errinfo);
}
else {
- VAR_INITIALIZED(th);
EC_TMPPOP_TAG();
error_handle(state);
- if (!NIL_P(th->ec->errinfo)) errinfo = th->ec->errinfo;
+ if (!NIL_P(ec->errinfo)) errinfo = ec->errinfo;
EC_REPUSH_TAG();
goto again;
}
EC_POP_TAG();
rb_set_safe_level_force(safe);
- th->ec->errinfo = errinfo;
+ ec->errinfo = errinfo;
}
void