aboutsummaryrefslogtreecommitdiff
path: root/src/bench/coin_selection.cpp
diff options
context:
space:
mode:
authorPasta <pasta@dashboost.org>2021-12-18 12:50:58 -0500
committerpasta <pasta@dashboost.org>2023-01-03 19:31:29 -0600
commitf2fc03ec856d7d19a20c482514350cced38f9504 (patch)
treef783af485b07464f29e0f5876db293a5ce44ca03 /src/bench/coin_selection.cpp
parent3f8591d46b46cec2c4effc01f8822222087d74c4 (diff)
downloadbitcoin-f2fc03ec856d7d19a20c482514350cced38f9504.tar.xz
refactor: use braced init for integer constants instead of c style casts
Diffstat (limited to 'src/bench/coin_selection.cpp')
-rw-r--r--src/bench/coin_selection.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/bench/coin_selection.cpp b/src/bench/coin_selection.cpp
index d02ddff37d..087e1442fe 100644
--- a/src/bench/coin_selection.cpp
+++ b/src/bench/coin_selection.cpp
@@ -99,9 +99,9 @@ static CAmount make_hard_case(int utxos, std::vector<OutputGroup>& utxo_pool)
utxo_pool.clear();
CAmount target = 0;
for (int i = 0; i < utxos; ++i) {
- target += (CAmount)1 << (utxos+i);
- add_coin((CAmount)1 << (utxos+i), 2*i, utxo_pool);
- add_coin(((CAmount)1 << (utxos+i)) + ((CAmount)1 << (utxos-1-i)), 2*i + 1, utxo_pool);
+ target += CAmount{1} << (utxos+i);
+ add_coin(CAmount{1} << (utxos+i), 2*i, utxo_pool);
+ add_coin((CAmount{1} << (utxos+i)) + (CAmount{1} << (utxos-1-i)), 2*i + 1, utxo_pool);
}
return target;
}