Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 694d00d

Browse filesBrowse files
authored
Merge pull request #1846 from thetic/signed-hex
Fix new ClangCL warnings
2 parents 874ff06 + 7d35673 commit 694d00d
Copy full SHA for 694d00d

File tree

Expand file treeCollapse file tree

2 files changed

+4
-4
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+4
-4
lines changed

‎src/CppUTest/SimpleString.cpp

Copy file name to clipboardExpand all lines: src/CppUTest/SimpleString.cpp
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -710,12 +710,12 @@ SimpleString StringFrom(void (*value)())
710710

711711
SimpleString HexStringFrom(long value)
712712
{
713-
return StringFromFormat("%lx", value);
713+
return HexStringFrom((unsigned long)value);
714714
}
715715

716716
SimpleString HexStringFrom(int value)
717717
{
718-
return StringFromFormat("%x", value);
718+
return HexStringFrom((unsigned int)value);
719719
}
720720

721721
SimpleString HexStringFrom(signed char value)
@@ -795,7 +795,7 @@ SimpleString StringFrom(cpputest_ulonglong value)
795795

796796
SimpleString HexStringFrom(cpputest_longlong value)
797797
{
798-
return StringFromFormat("%llx", value);
798+
return HexStringFrom((cpputest_ulonglong)value);
799799
}
800800

801801
SimpleString HexStringFrom(cpputest_ulonglong value)

‎src/CppUTestExt/MockExpectedCall.cpp

Copy file name to clipboardExpand all lines: src/CppUTestExt/MockExpectedCall.cpp
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@ SimpleString MockCheckedExpectedCall::callToString()
423423
str += ", other parameters are ignored";
424424
}
425425

426-
str += StringFromFormat(" (expected %d call%s, called %d time%s)",
426+
str += StringFromFormat(" (expected %u call%s, called %u time%s)",
427427
expectedCalls_, (expectedCalls_ == 1) ? "" : "s", actualCalls_, (actualCalls_ == 1) ? "" : "s" );
428428

429429
return str;

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.