提交 0dafa0b3 编写于 作者: A Alexander Brevig

use unary minus on the incoming int instead of the casted uint

上级 a78c7997
...@@ -321,7 +321,7 @@ void UnityPrintNumber(const UNITY_INT number_to_print) ...@@ -321,7 +321,7 @@ void UnityPrintNumber(const UNITY_INT number_to_print)
{ {
/* A negative number, including MIN negative */ /* A negative number, including MIN negative */
UNITY_OUTPUT_CHAR('-'); UNITY_OUTPUT_CHAR('-');
number = -number; number = (UNITY_UINT)-number_to_print;
} }
UnityPrintNumberUnsigned(number); UnityPrintNumberUnsigned(number);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册