提交 85f73fa8 编写于 作者: B Behdad Esfahbod

Only printout class name in tracing, if one is available

Makes debug output much more pleasant.
上级 98619ce4
......@@ -531,8 +531,12 @@ _hb_debug_msg_va (const char *what,
else
fprintf (stderr, " ├╴");
if (func)
fprintf (stderr, "%s: ", func);
if (func) {
/* If there's a class name, just write that. */
const char *dotdot = strstr (func, "::");
unsigned int func_len = dotdot ? dotdot - func : strlen (func);
fprintf (stderr, "%*s: ", func_len, func);
}
if (message)
vfprintf (stderr, message, ap);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册