summaryrefslogtreecommitdiff
path: root/vm_eval.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-27 17:39:17 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-27 17:39:17 +0000
commit496267023c490e717ad0598bf1e3364835b734a4 (patch)
tree476fe618ca22d55f6c92e41da1c444e4dc255432 /vm_eval.c
parentfcc5a19e2f9801217691a842250db937de3ea5ee (diff)
fix missed script_compiled events. [Bug #15471]
* ruby.c (process_options): script_compiled events are missed on command line -e or specified file. this commit fix it. [Bug #15471] This patch should be backport to Ruby 2.6 branch. * vm_core.h (rb_exec_event_hook_script_compiled): introduce utility function to invoke a script_compiled event. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66595 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_eval.c')
-rw-r--r--vm_eval.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/vm_eval.c b/vm_eval.c
index a8764e2fa4..0e7047af65 100644
--- a/vm_eval.c
+++ b/vm_eval.c
@@ -1293,8 +1293,8 @@ eval_make_iseq(VALUE src, VALUE fname, int line, const rb_binding_t *bind,
printf("%s\n", StringValuePtr(disasm));
}
- EXEC_EVENT_HOOK(GET_EC(), RUBY_EVENT_SCRIPT_COMPILED, GET_EC()->cfp->self, 0, 0, 0,
- rb_ary_new_from_args(2, src, (VALUE)iseq));
+ rb_exec_event_hook_script_compiled(GET_EC(), iseq, src);
+
return iseq;
}