diff options
Diffstat (limited to 'src/test/fuzz/integer.cpp')
-rw-r--r-- | src/test/fuzz/integer.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/test/fuzz/integer.cpp b/src/test/fuzz/integer.cpp index 8f1d7b6d45..b9e3154106 100644 --- a/src/test/fuzz/integer.cpp +++ b/src/test/fuzz/integer.cpp @@ -69,7 +69,7 @@ FUZZ_TARGET(integer, .init = initialize_integer) const bool b = fuzzed_data_provider.ConsumeBool(); const Consensus::Params& consensus_params = Params().GetConsensus(); - (void)CheckProofOfWork(u256, u32, consensus_params); + (void)CheckProofOfWorkImpl(u256, u32, consensus_params); if (u64 <= MAX_MONEY) { const uint64_t compressed_money_amount = CompressAmount(u64); assert(u64 == DecompressAmount(compressed_money_amount)); @@ -78,8 +78,8 @@ FUZZ_TARGET(integer, .init = initialize_integer) } else { (void)CompressAmount(u64); } - static const uint256 u256_min(uint256S("0000000000000000000000000000000000000000000000000000000000000000")); - static const uint256 u256_max(uint256S("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff")); + constexpr uint256 u256_min{"0000000000000000000000000000000000000000000000000000000000000000"}; + constexpr uint256 u256_max{"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"}; const std::vector<uint256> v256{u256, u256_min, u256_max}; (void)ComputeMerkleRoot(v256); (void)DecompressAmount(u64); @@ -140,7 +140,7 @@ FUZZ_TARGET(integer, .init = initialize_integer) const arith_uint256 au256 = UintToArith256(u256); assert(ArithToUint256(au256) == u256); - assert(uint256S(au256.GetHex()) == u256); + assert(uint256::FromHex(au256.GetHex()).value() == u256); (void)au256.bits(); (void)au256.GetCompact(/* fNegative= */ false); (void)au256.GetCompact(/* fNegative= */ true); |