Skip to content

Commit

Permalink
FormatIntTest: FormatDec: don't assume signedness of char type
Browse files Browse the repository at this point in the history
Thanks to Eugene V. Lyubimkin for the patch.
  • Loading branch information
vitaut committed Jun 22, 2015
1 parent 2e874af commit 8450f5e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/format-test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1532,7 +1532,7 @@ std::string format_decimal(T value) {
}

TEST(FormatIntTest, FormatDec) {
EXPECT_EQ("-42", format_decimal(static_cast<char>(-42)));
EXPECT_EQ("-42", format_decimal(static_cast<signed char>(-42)));
EXPECT_EQ("-42", format_decimal(static_cast<short>(-42)));
std::ostringstream os;
os << std::numeric_limits<unsigned short>::max();
Expand Down

0 comments on commit 8450f5e

Please sign in to comment.