Commit 07bcd6be authored by Yukihiro Matsumoto's avatar Yukihiro Matsumoto

cdump.c: pool may contain fixnum value

parent 0e9e0693
...@@ -139,6 +139,8 @@ make_cdump_irep(mrb_state *mrb, int irep_no, FILE *f) ...@@ -139,6 +139,8 @@ make_cdump_irep(mrb_state *mrb, int irep_no, FILE *f)
switch (irep->pool[n].tt) { switch (irep->pool[n].tt) {
case MRB_TT_FLOAT: case MRB_TT_FLOAT:
SOURCE_CODE(" irep->pool[%d] = mrb_float_value(%.16e);", n, irep->pool[n].value.f); break; SOURCE_CODE(" irep->pool[%d] = mrb_float_value(%.16e);", n, irep->pool[n].value.f); break;
case MRB_TT_FIXNUM:
SOURCE_CODE(" irep->pool[%d] = mrb_fixnum_value(%d);", n, irep->pool[n].value.i); break;
case MRB_TT_STRING: case MRB_TT_STRING:
str_len = str_format_len(irep->pool[n]) + 1; str_len = str_format_len(irep->pool[n]) + 1;
if ( str_len > buf_len ) { if ( str_len > buf_len ) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment