Poco::Logger print int8_t value

徘徊边缘 提交于 2019-12-13 03:55:09

问题


I am trying to print int8_t value with Poco::Logger in this way:

using myint8_t = signed char;
myint8_t var;
var = 10;
logger().information("%c", var);
logger().information("%d", var);
logger().information("%i", var);

But as output have error which tells me that argument does not match the format specifier:

2018-10-02 00:12:40.627 [Information] [ERRFMT]
2018-10-02 00:12:40.627 [Information] [ERRFMT]
2018-10-02 00:12:40.627 [Information] [ERRFMT]

Where is my mistake and how to print signed char value with Poco::Logger? Thanks.

来源:https://stackoverflow.com/questions/52599087/pocologger-print-int8-t-value

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!