Fix -Wsign-compare warnings

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@215483 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
David Blaikie 2014-08-12 23:23:05 +00:00
parent 151f8cef74
commit 8ebea0132d

View File

@ -681,16 +681,16 @@ TEST(APIntTest, nearestLogBase2) {
TEST(APIntTest, SelfMoveAssignment) {
APInt X(32, 0xdeadbeef);
X = std::move(X);
EXPECT_EQ(32, X.getBitWidth());
EXPECT_EQ(32u, X.getBitWidth());
EXPECT_EQ(0xdeadbeefULL, X.getLimitedValue());
uint64_t Bits[] = {0xdeadbeefdeadbeefULL, 0xdeadbeefdeadbeefULL};
APInt Y(128, Bits);
Y = std::move(Y);
EXPECT_EQ(128, Y.getBitWidth());
EXPECT_EQ(128u, Y.getBitWidth());
EXPECT_EQ(~0ULL, Y.getLimitedValue());
const uint64_t *Raw = Y.getRawData();
EXPECT_EQ(2, Y.getNumWords());
EXPECT_EQ(2u, Y.getNumWords());
EXPECT_EQ(0xdeadbeefdeadbeefULL, Raw[0]);
EXPECT_EQ(0xdeadbeefdeadbeefULL, Raw[1]);
}