aboutsummaryrefslogtreecommitdiff
path: root/src/arith_uint256.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/arith_uint256.h')
-rw-r--r--src/arith_uint256.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/arith_uint256.h b/src/arith_uint256.h
index 5cc273be27..bd0360087d 100644
--- a/src/arith_uint256.h
+++ b/src/arith_uint256.h
@@ -8,6 +8,7 @@
#include <assert.h>
#include <cstring>
+#include <limits>
#include <stdexcept>
#include <stdint.h>
#include <string>
@@ -189,7 +190,7 @@ public:
{
// prefix operator
int i = 0;
- while (i < WIDTH && --pn[i] == (uint32_t)-1)
+ while (i < WIDTH && --pn[i] == std::numeric_limits<uint32_t>::max())
i++;
return *this;
}