diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2020-06-16 18:44:58 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2020-06-16 18:44:58 +0900 |
commit | 318d52e820c9ed1bc4c12aa97af49a89953649bc (patch) | |
tree | cbeaa0c9945d67a0e2d62faa35a4cc24afcff346 /vm_insnhelper.c | |
parent | 26c179d7e7e7ae0eb21050659c3e8778358230ab (diff) |
Revert "Replaced accessors of `Struct` with `invokebuiltin`"
This reverts commit 19cabe8b09d92d033c244f32ff622b8e513375f1,
which didn't support tool/lib/iseq_loader_checker.rb.
Diffstat (limited to 'vm_insnhelper.c')
-rw-r--r-- | vm_insnhelper.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/vm_insnhelper.c b/vm_insnhelper.c index 8f1b6e7307..611739e957 100644 --- a/vm_insnhelper.c +++ b/vm_insnhelper.c @@ -3621,6 +3621,20 @@ vm_once_clear(VALUE data) return Qnil; } +rb_control_frame_t * +FUNC_FASTCALL(rb_vm_opt_struct_aref)(rb_execution_context_t *ec, rb_control_frame_t *reg_cfp) +{ + TOPN(0) = rb_struct_aref(GET_SELF(), TOPN(0)); + return reg_cfp; +} + +rb_control_frame_t * +FUNC_FASTCALL(rb_vm_opt_struct_aset)(rb_execution_context_t *ec, rb_control_frame_t *reg_cfp) +{ + rb_struct_aset(GET_SELF(), TOPN(0), TOPN(1)); + return reg_cfp; +} + /* defined insn */ static enum defined_type |