Commit b780e630 authored by Yukihiro Matsumoto's avatar Yukihiro Matsumoto

mrb_get_args(f) should convert using to_f

parent eac8e4a3
......@@ -374,7 +374,12 @@ mrb_get_args(mrb_state *mrb, const char *format, ...)
*p = (argc > i) ? (mrb_float)mrb_fixnum(*sp) : 0;
break;
default:
// error
{
mrb_value tmp;
tmp = mrb_convert_type(mrb, *sp, MRB_TT_FLOAT, "Float", "to_f");
*p = mrb_float(tmp);
}
break;
}
i++; sp++;
......
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