aboutsummaryrefslogtreecommitdiffstats
path: root/vm_method.c
diff options
context:
space:
mode:
Diffstat (limited to 'vm_method.c')
-rw-r--r--vm_method.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/vm_method.c b/vm_method.c
index 43b5d2aafc..5a8439649a 100644
--- a/vm_method.c
+++ b/vm_method.c
@@ -562,6 +562,7 @@ rb_add_method_iseq(VALUE klass, ID mid, VALUE iseqval, rb_cref_t *cref, rb_metho
iseq_body.iseqptr = iseq;
iseq_body.cref = cref;
rb_add_method(klass, mid, VM_METHOD_TYPE_ISEQ, &iseq_body, visi);
+ RB_GC_GUARD(iseqval);
}
static rb_method_entry_t *