summaryrefslogtreecommitdiff
path: root/iseq.c
diff options
context:
space:
mode:
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/iseq.c b/iseq.c
index 7e1ac877c1..f1b38240a8 100644
--- a/iseq.c
+++ b/iseq.c
@@ -1987,7 +1987,14 @@ iseq_data_to_ary(rb_iseq_t *iseq)
}
break;
case TS_FUNCPTR:
- rb_ary_push(ary, Qnil);
+ {
+#if SIZEOF_VALUE <= SIZEOF_LONG
+ VALUE val = LONG2NUM((SIGNED_VALUE)*seq);
+#else
+ VALUE val = LL2NUM((SIGNED_VALUE)*seq);
+#endif
+ rb_ary_push(ary, val);
+ }
break;
default:
rb_bug("unknown operand: %c", insn_op_type(insn, j));