mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Avoid call to_s during backtrace traversal
This commit is contained in:
+1
-1
@@ -79,7 +79,7 @@ get_backtrace_i(mrb_state *mrb, struct backtrace_location *loc, void *data)
|
||||
ary = mrb_obj_value((struct RArray*)data);
|
||||
|
||||
str = mrb_str_new_cstr(mrb, loc->filename);
|
||||
str = mrb_format(mrb, "%S:%S", str, mrb_fixnum_value(loc->lineno));
|
||||
str = mrb_format(mrb, "%S:%S", str, mrb_fixnum_to_str(mrb, mrb_fixnum_value(loc->lineno), 10));
|
||||
|
||||
if (loc->method) {
|
||||
mrb_str_cat_lit(mrb, str, ":in ");
|
||||
|
||||
Reference in New Issue
Block a user