summaryrefslogtreecommitdiff
path: root/iseq.c
diff options
context:
space:
mode:
authornagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-05 14:35:07 +0000
committernagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-05 14:35:07 +0000
commitaba207b7620d963e212e4187213db7e1eee7a790 (patch)
treefd24dfe63ee07d998d680b424d50930144abb558 /iseq.c
parentf35b27b5abefb52e6e3dac2b33f4f7bfe8b5ca72 (diff)
merge revision(s) 64736,65567: [Backport #15270]
iseq.c: prefix rb_ to non-static iseq functions I assume we always prefix rb_ to non-static functions to avoid conflict. These functions are not exported and safe to be renamed. iseq.h: ditto compile.c: ditto Fix TracePoint for nested iseq loaded from binary [Bug#14702] When loading iseq from binary while a TracePoint is on, we need to recompile instructions to their "trace_" variant. Before this commit we only recompiled instructions in the top level iseq, which meant that TracePoint was malfunctioning for code inside module/class/method definitions. * compile.c: Move rb_iseq_init_trace to rb_ibf_load_iseq_complete. It is called on all iseqs during loading. * test_iseq.rb: Test that tracepoints fire within children iseq when using load_from_binary. This patch is from: Alan Wu <XrXr@users.noreply.github.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@66225 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/iseq.c b/iseq.c
index 08eb15c7df..7d7398607e 100644
--- a/iseq.c
+++ b/iseq.c
@@ -350,7 +350,7 @@ static void validate_get_insn_info(rb_iseq_t *iseq);
#endif
void
-iseq_init_trace(rb_iseq_t *iseq)
+rb_iseq_init_trace(rb_iseq_t *iseq)
{
iseq->aux.trace_events = 0;
if (ruby_vm_event_enabled_flags & ISEQ_TRACE_EVENTS) {
@@ -377,7 +377,7 @@ finish_iseq_build(rb_iseq_t *iseq)
rb_exc_raise(err);
}
- iseq_init_trace(iseq);
+ rb_iseq_init_trace(iseq);
return Qtrue;
}
@@ -1000,7 +1000,7 @@ iseqw_check(VALUE iseqw)
rb_iseq_t *iseq = DATA_PTR(iseqw);
if (!iseq->body) {
- ibf_load_iseq_complete(iseq);
+ rb_ibf_load_iseq_complete(iseq);
}
if (!iseq->body->location.label) {
@@ -2652,7 +2652,7 @@ iseqw_to_binary(int argc, VALUE *argv, VALUE self)
{
VALUE opt;
rb_scan_args(argc, argv, "01", &opt);
- return iseq_ibf_dump(iseqw_check(self), opt);
+ return rb_iseq_ibf_dump(iseqw_check(self), opt);
}
/*
@@ -2671,7 +2671,7 @@ iseqw_to_binary(int argc, VALUE *argv, VALUE self)
static VALUE
iseqw_s_load_from_binary(VALUE self, VALUE str)
{
- return iseqw_new(iseq_ibf_load(str));
+ return iseqw_new(rb_iseq_ibf_load(str));
}
/*
@@ -2683,7 +2683,7 @@ iseqw_s_load_from_binary(VALUE self, VALUE str)
static VALUE
iseqw_s_load_from_binary_extra_data(VALUE self, VALUE str)
{
- return iseq_ibf_load_extra_data(str);
+ return rb_iseq_ibf_load_extra_data(str);
}
/*