mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-27 01:06:06 +00:00
Silence gcc warning in testcase [NFC]
Without the fix gcc (7.4.0) complains with ../unittests/ADT/APIntTest.cpp: In member function 'virtual void {anonymous}::APIntTest_MultiplicativeInverseExaustive_Test::TestBody()': ../unittests/ADT/APIntTest.cpp:2510:36: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare] for (unsigned Value = 0; Value < (1 << BitWidth); ++Value) { ~~~~~~^~~~~~~~~~~~~~~~~ llvm-svn: 364624
This commit is contained in:
parent
e832adea0f
commit
2adab5a142
@ -2507,7 +2507,7 @@ TEST(APIntTest, SolveQuadraticEquationWrap) {
|
||||
|
||||
TEST(APIntTest, MultiplicativeInverseExaustive) {
|
||||
for (unsigned BitWidth = 1; BitWidth <= 16; ++BitWidth) {
|
||||
for (unsigned Value = 0; Value < (1 << BitWidth); ++Value) {
|
||||
for (unsigned Value = 0; Value < (1u << BitWidth); ++Value) {
|
||||
APInt V = APInt(BitWidth, Value);
|
||||
APInt MulInv =
|
||||
V.zext(BitWidth + 1)
|
||||
|
Loading…
x
Reference in New Issue
Block a user