aboutsummaryrefslogtreecommitdiffstats
path: root/compile.c
diff options
context:
space:
mode:
authorPeter Zhu <peter@peterzhu.ca>2023-01-19 14:47:17 -0500
committerPeter Zhu <peter@peterzhu.ca>2023-01-20 08:51:39 -0500
commit056e7a0154fe4c71eca3726c878bb3da7e4138f8 (patch)
tree0cc48f743143edbb7801e5dc103b670b7ad62145 /compile.c
parent76e3d853ab33d31ab9d5ae6f88b406841e8dbbf2 (diff)
downloadruby-056e7a0154fe4c71eca3726c878bb3da7e4138f8.tar.gz
Make all of the references of iseq movable
Diffstat (limited to 'compile.c')
-rw-r--r--compile.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/compile.c b/compile.c
index c20ef48c43..997ec75dfb 100644
--- a/compile.c
+++ b/compile.c
@@ -10736,7 +10736,7 @@ iseq_build_kw(rb_iseq_t *iseq, VALUE params, VALUE keywords)
}
void
-rb_iseq_mark_insn_storage(struct iseq_compile_data_storage *storage)
+rb_iseq_mark_and_update_insn_storage(struct iseq_compile_data_storage *storage)
{
INSN *iobj = 0;
size_t size = sizeof(INSN);
@@ -10772,13 +10772,7 @@ rb_iseq_mark_insn_storage(struct iseq_compile_data_storage *storage)
case TS_VALUE:
case TS_IC: // constant path array
case TS_CALLDATA: // ci is stored.
- {
- VALUE op = OPERAND_AT(iobj, j);
-
- if (!SPECIAL_CONST_P(op)) {
- rb_gc_mark(op);
- }
- }
+ rb_gc_mark_and_move(&OPERAND_AT(iobj, j));
break;
default:
break;