diff options
author | Yusuke Endoh <[email protected]> | 2021-06-08 17:34:08 +0900 |
---|---|---|
committer | Yusuke Endoh <[email protected]> | 2021-06-18 03:35:38 +0900 |
commit | dfba87cd622f9699f54d1d0b8c057deb428874b6 (patch) | |
tree | bd07194e1c0dc96cd517cbf1e3c37389e5d48614 /iseq.c | |
parent | ea6062898ad0d66ede0a1866028c0605c357e2cb (diff) |
Make it possible to get AST::Node from Thread::Backtrace::Location
RubyVM::AST.of(Thread::Backtrace::Location) returns a node that
corresponds to the location. Typically, the node is a method call, but
not always.
This change also includes iseq's dump/load support of node_ids for each
instructions.
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/4558
Diffstat (limited to 'iseq.c')
-rw-r--r-- | iseq.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -2998,7 +2998,7 @@ iseq_data_to_ary(const rb_iseq_t *iseq) INT2FIX(iseq_body->location.code_location.end_pos.lineno), INT2FIX(iseq_body->location.code_location.end_pos.column))); #ifdef EXPERIMENTAL_ISEQ_NODE_ID - rb_hash_aset(misc, ID2SYM(rb_intern("node_ids_for_each_insn")), node_ids); + rb_hash_aset(misc, ID2SYM(rb_intern("node_ids")), node_ids); #endif /* |