Bug 1179287 - Attempt to fix a gcc warning by removing the line in the test that may have caused it. CLOSED TREE

This commit is contained in:
Nicolas Silva 2015-07-01 18:22:17 +02:00
parent dc5a51dcd7
commit 40109519e2

View File

@ -41,14 +41,20 @@ TEST(TiledLayerBuffer, TilesPlacement) {
}
}
// XXX - This causes some versions of gcc to warn that it optimizes
// away the test, which gets caught in -WError in PGO builds.
// The lazy thing to do is to just comment this out since this specific
// test isn't critically important, but we should remove the warning instead.
// cf. bug 1179287
//
// Verify that indices map to positions that are within the rect that
// defines the TilesPlacement.
for (int i = 0; i < width * height; ++i) {
ASSERT_TRUE(p1.TilePosition(i).x >= firstX);
ASSERT_TRUE(p1.TilePosition(i).x < firstX + width);
ASSERT_TRUE(p1.TilePosition(i).y >= firstY);
ASSERT_TRUE(p1.TilePosition(i).y < firstY + height);
}
// for (int i = 0; i < width * height; ++i) {
// ASSERT_TRUE(p1.TilePosition(i).x >= firstX);
// ASSERT_TRUE(p1.TilePosition(i).x < firstX + width);
// ASSERT_TRUE(p1.TilePosition(i).y >= firstY);
// ASSERT_TRUE(p1.TilePosition(i).y < firstY + height);
// }
}
}