提交 9109f1e9 编写于 作者: B Behdad Esfahbod

[util/hb-shape] Accept an empty output-format that would skip output

Useful for benchmarking, to avoid buffer serialization overhead (which
seems to by far dominate shaping!)
上级 86564085
......@@ -48,7 +48,10 @@ struct output_buffer_t
output_format = HB_BUFFER_SERIALIZE_FORMAT_TEXT;
else
output_format = hb_buffer_serialize_format_from_string (options.output_format, -1);
if (!hb_buffer_serialize_format_to_string (output_format))
/* An empty "output_format" parameter basically skips output generating.
* Useful for benchmarking. */
if (*options.output_format &&
!hb_buffer_serialize_format_to_string (output_format))
{
if (options.explicit_output_format)
fail (false, "Unknown output format `%s'; supported formats are: %s",
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册