mirror of
https://github.com/dogecoin/dogecoin.git
synced 2026-01-31 10:30:52 +00:00
net: explicitly include std::array
On boost 1.81 std::array is no longer included by default and
causes a compile error on net_processing.cpp:
macOS with apple clang 14.0:
CXX libdogecoin_server_a-net_processing.o
net_processing.cpp:1112:47: error: implicit instantiation of undefined template 'std::array<std::pair<unsigned long long, CNode *>, 2>'
std::array<std::pair<uint64_t, CNode*>,2> best{{{0, nullptr}, {0, nullptr}}};
debian:exprimental with gcc 12.1:
net_processing.cpp: In function 'void RelayAddress(const CAddress&, bool, CConnman&)':
net_processing.cpp:1112:47: error: variable 'std::array<std::pair<long unsigned int, CNode*>, 2> best' has initializer but incomplete type
1112 | std::array<std::pair<uint64_t, CNode*>,2> best{{{0, nullptr}, {0, nullptr}}};
|
this commit fixes the problem by explicitly including <array>.
This commit is contained in:
parent
4b73ae26b6
commit
5a5f1955f7
@ -31,6 +31,7 @@
|
||||
#include "utilstrencodings.h"
|
||||
#include "validationinterface.h"
|
||||
|
||||
#include <array>
|
||||
#include <boost/thread.hpp>
|
||||
|
||||
#if defined(NDEBUG)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user