Skip to content

Commit 6dbcc74

Browse files
committed
Merge #10193: scripted-diff: Remove #include <boost/foreach.hpp>
b1268a1 clang-format: Delete ForEachMacros (Jorge Timón) 5995735 scripted-diff: Remove #include <boost/foreach.hpp> (Jorge Timón) 3eff827 scripted-diff: Remove BOOST_REVERSE_FOREACH (Jorge Timón) 33aed5b Fix const_reverse_iterator constructor (pass const ptr) (Jorge Timón) 300851e Introduce src/reverse_iterator.hpp and include it... (Jorge Timón) Tree-SHA512: df3405328e9602d0a433ac134ba59a5c9a6202ef64188df2f94a59b2ce58dec7c988b25d0671c7937de516a96b2e6daeb9d04c82fa363b616ee4cf6e9cb0fac6
2 parents 7397af9 + b1268a1 commit 6dbcc74

38 files changed

+53
-39
lines changed

src/.clang-format

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ ContinuationIndentWidth: 4
2323
Cpp11BracedListStyle: true
2424
DerivePointerAlignment: false
2525
DisableFormat: false
26-
ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH, BOOST_REVERSE_FOREACH ]
2726
IndentCaseLabels: false
2827
IndentFunctionDeclarationAfterType: false
2928
IndentWidth: 4

src/Makefile.am

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ BITCOIN_CORE_H = \
124124
pow.h \
125125
protocol.h \
126126
random.h \
127+
reverse_iterator.h \
127128
reverselock.h \
128129
rpc/blockchain.h \
129130
rpc/client.h \

src/bench/coin_selection.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
#include "bench.h"
66
#include "wallet/wallet.h"
77

8-
#include <boost/foreach.hpp>
98
#include <set>
109

1110
static void addCoin(const CAmount& nValue, const CWallet& wallet, std::vector<COutput>& vCoins)

src/bloom.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
#include <math.h>
1515
#include <stdlib.h>
1616

17-
#include <boost/foreach.hpp>
1817

1918
#define LN2SQUARED 0.4804530139182014246671025263266649717305529515945455
2019
#define LN2 0.6931471805599453094172321214581765680755001343602552

src/checkpoints.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,20 @@
66

77
#include "chain.h"
88
#include "chainparams.h"
9+
#include "reverse_iterator.h"
910
#include "validation.h"
1011
#include "uint256.h"
1112

1213
#include <stdint.h>
1314

14-
#include <boost/foreach.hpp>
1515

1616
namespace Checkpoints {
1717

1818
CBlockIndex* GetLastCheckpoint(const CCheckpointData& data)
1919
{
2020
const MapCheckpoints& checkpoints = data.mapCheckpoints;
2121

22-
BOOST_REVERSE_FOREACH(const MapCheckpoints::value_type& i, checkpoints)
22+
for (const MapCheckpoints::value_type& i : reverse_iterate(checkpoints))
2323
{
2424
const uint256& hash = i.second;
2525
BlockMap::const_iterator t = mapBlockIndex.find(hash);

src/checkqueue.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
#include <algorithm>
1111
#include <vector>
1212

13-
#include <boost/foreach.hpp>
1413
#include <boost/thread/condition_variable.hpp>
1514
#include <boost/thread/mutex.hpp>
1615

src/core_write.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
#include "utilmoneystr.h"
1616
#include "utilstrencodings.h"
1717

18-
#include <boost/foreach.hpp>
1918

2019
std::string FormatScript(const CScript& script)
2120
{

src/httprpc.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
#include <stdio.h>
1919

2020
#include <boost/algorithm/string.hpp> // boost::trim
21-
#include <boost/foreach.hpp>
2221

2322
/** WWW-Authenticate to present with 401 Unauthorized response */
2423
static const char* WWW_AUTH_HEADER_DATA = "Basic realm=\"jsonrpc\"";

src/memusage.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
#include <unordered_map>
1616
#include <unordered_set>
1717

18-
#include <boost/foreach.hpp>
1918

2019
namespace memusage
2120
{

src/net.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333
#include <arpa/inet.h>
3434
#endif
3535

36-
#include <boost/foreach.hpp>
3736
#include <boost/signals2/signal.hpp>
3837

3938
class CScheduler;

0 commit comments

Comments
 (0)