Commit aec5ac49 authored by mattn's avatar mattn

Remove unused mrb_sprintf

parent 6954153f
......@@ -264,22 +264,6 @@ mrb_name_error(mrb_state *mrb, mrb_sym id, const char *fmt, ...)
mrb_exc_raise(mrb, exc);
}
mrb_value
mrb_sprintf(mrb_state *mrb, const char *fmt, ...)
{
va_list args;
char buf[256];
int n;
va_start(args, fmt);
n = vsnprintf(buf, sizeof(buf), fmt, args);
va_end(args);
if (n < 0) {
n = 0;
}
return mrb_str_new(mrb, buf, n);
}
void
mrb_warn(const char *fmt, ...)
{
......
......@@ -13,7 +13,6 @@ int sysexit_status(mrb_state *mrb, mrb_value err);
mrb_value mrb_exc_new3(mrb_state *mrb, struct RClass* c, mrb_value str);
mrb_value make_exception(mrb_state *mrb, int argc, mrb_value *argv, int isstr);
mrb_value mrb_make_exception(mrb_state *mrb, int argc, mrb_value *argv);
mrb_value mrb_sprintf(mrb_state *mrb, const char *fmt, ...);
void mrb_name_error(mrb_state *mrb, mrb_sym id, const char *fmt, ...);
void mrb_exc_print(mrb_state *mrb, struct RObject *exc);
......
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