diff --git a/src/.clang-tidy b/src/.clang-tidy index 1cf270833a2..544bd5ac0c1 100644 --- a/src/.clang-tidy +++ b/src/.clang-tidy @@ -9,6 +9,7 @@ bugprone-lambda-function-name, bugprone-unhandled-self-assignment, misc-unused-using-decls, misc-no-recursion, +modernize-deprecated-headers, modernize-use-default-member-init, modernize-use-emplace, modernize-use-equals-default, @@ -29,6 +30,8 @@ readability-redundant-string-init, HeaderFilterRegex: '.' WarningsAsErrors: '*' CheckOptions: + - key: modernize-deprecated-headers.CheckHeaderFile + value: false - key: performance-move-const-arg.CheckTriviallyCopyableMove value: false - key: bugprone-unhandled-self-assignment.WarnOnlyIfThisHasSuspiciousField diff --git a/src/base58.cpp b/src/base58.cpp index d0e1ab465e4..19a5bd3e550 100644 --- a/src/base58.cpp +++ b/src/base58.cpp @@ -9,8 +9,8 @@ #include #include -#include -#include +#include +#include #include diff --git a/src/bech32.cpp b/src/bech32.cpp index 81695acebaa..ed918622176 100644 --- a/src/bech32.cpp +++ b/src/bech32.cpp @@ -1,5 +1,5 @@ // Copyright (c) 2017, 2021 Pieter Wuille -// Copyright (c) 2021-2022 The Bitcoin Core developers +// Copyright (c) 2021-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -7,7 +7,7 @@ #include #include -#include +#include #include #include diff --git a/src/bech32.h b/src/bech32.h index 6d5a68ec5a1..ba4c79bb869 100644 --- a/src/bech32.h +++ b/src/bech32.h @@ -1,5 +1,5 @@ // Copyright (c) 2017, 2021 Pieter Wuille -// Copyright (c) 2021 The Bitcoin Core developers +// Copyright (c) 2021-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -14,7 +14,7 @@ #ifndef BITCOIN_BECH32_H #define BITCOIN_BECH32_H -#include +#include #include #include diff --git a/src/bench/examples.cpp b/src/bench/examples.cpp index 671902ef2fb..0769b80da0a 100644 --- a/src/bench/examples.cpp +++ b/src/bench/examples.cpp @@ -1,11 +1,11 @@ -// Copyright (c) 2015-2022 The Bitcoin Core developers +// Copyright (c) 2015-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include // Extremely fast-running benchmark: -#include +#include volatile double sum = 0.0; // volatile, global so not optimized away diff --git a/src/bench/parse_hex.cpp b/src/bench/parse_hex.cpp index db3ead043c8..fa08f5d84a1 100644 --- a/src/bench/parse_hex.cpp +++ b/src/bench/parse_hex.cpp @@ -1,12 +1,13 @@ -// Copyright (c) 2024- The Bitcoin Core developers +// Copyright (c) 2024-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include #include -#include #include + #include +#include #include #include diff --git a/src/bip324.cpp b/src/bip324.cpp index 73f51a195ee..9c5a1572bb7 100644 --- a/src/bip324.cpp +++ b/src/bip324.cpp @@ -16,9 +16,9 @@ #include #include -#include -#include +#include #include +#include #include #include diff --git a/src/chainparamsbase.cpp b/src/chainparamsbase.cpp index 060d519d920..d816d1af91c 100644 --- a/src/chainparamsbase.cpp +++ b/src/chainparamsbase.cpp @@ -1,5 +1,5 @@ // Copyright (c) 2010 Satoshi Nakamoto -// Copyright (c) 2009-2021 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -9,7 +9,7 @@ #include #include -#include +#include void SetupChainParamsBaseOptions(ArgsManager& argsman) { diff --git a/src/cluster_linearize.h b/src/cluster_linearize.h index 217c4700afe..17b7e6b27a0 100644 --- a/src/cluster_linearize.h +++ b/src/cluster_linearize.h @@ -6,11 +6,11 @@ #define BITCOIN_CLUSTER_LINEARIZE_H #include +#include #include #include -#include -#include #include +#include #include #include diff --git a/src/coins.h b/src/coins.h index 61fb4af6420..6725d5a51f6 100644 --- a/src/coins.h +++ b/src/coins.h @@ -1,5 +1,5 @@ // Copyright (c) 2009-2010 Satoshi Nakamoto -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -16,8 +16,8 @@ #include #include -#include -#include +#include +#include #include #include diff --git a/src/common/args.h b/src/common/args.h index 8d9daf5f65d..6c5ac48ae3e 100644 --- a/src/common/args.h +++ b/src/common/args.h @@ -1,4 +1,4 @@ -// Copyright (c) 2023 The Bitcoin Core developers +// Copyright (c) 2023-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -11,12 +11,12 @@ #include #include +#include #include #include #include #include #include -#include #include #include #include diff --git a/src/consensus/consensus.h b/src/consensus/consensus.h index cffe9cdafd7..71b5fe2468d 100644 --- a/src/consensus/consensus.h +++ b/src/consensus/consensus.h @@ -1,13 +1,13 @@ // Copyright (c) 2009-2010 Satoshi Nakamoto -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_CONSENSUS_CONSENSUS_H #define BITCOIN_CONSENSUS_CONSENSUS_H +#include #include -#include /** The maximum allowed size for a serialized block, in bytes (only for buffer size limits) */ static const unsigned int MAX_BLOCK_SERIALIZED_SIZE = 4000000; diff --git a/src/consensus/tx_verify.h b/src/consensus/tx_verify.h index d2cf792cf3f..8b7e6d6b385 100644 --- a/src/consensus/tx_verify.h +++ b/src/consensus/tx_verify.h @@ -1,4 +1,4 @@ -// Copyright (c) 2017-2021 The Bitcoin Core developers +// Copyright (c) 2017-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -7,7 +7,7 @@ #include -#include +#include #include class CBlockIndex; diff --git a/src/crypto/aes.cpp b/src/crypto/aes.cpp index 2afcbd16292..40df5690e0f 100644 --- a/src/crypto/aes.cpp +++ b/src/crypto/aes.cpp @@ -1,10 +1,10 @@ -// Copyright (c) 2016-2019 The Bitcoin Core developers +// Copyright (c) 2016-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include -#include +#include extern "C" { #include diff --git a/src/crypto/chacha20.cpp b/src/crypto/chacha20.cpp index acb860e9b46..91064050f48 100644 --- a/src/crypto/chacha20.cpp +++ b/src/crypto/chacha20.cpp @@ -12,7 +12,7 @@ #include #include -#include +#include #define QUARTERROUND(a,b,c,d) \ a += b; d = std::rotl(d ^ a, 16); \ diff --git a/src/crypto/chacha20.h b/src/crypto/chacha20.h index 06eb10781c5..6653c2c9733 100644 --- a/src/crypto/chacha20.h +++ b/src/crypto/chacha20.h @@ -9,8 +9,8 @@ #include #include +#include #include -#include #include // classes for ChaCha20 256-bit stream cipher developed by Daniel J. Bernstein diff --git a/src/crypto/chacha20poly1305.cpp b/src/crypto/chacha20poly1305.cpp index 4c7da07d7ec..5b918d9b910 100644 --- a/src/crypto/chacha20poly1305.cpp +++ b/src/crypto/chacha20poly1305.cpp @@ -4,13 +4,13 @@ #include -#include #include +#include #include #include #include -#include +#include #include AEADChaCha20Poly1305::AEADChaCha20Poly1305(std::span key) noexcept : m_chacha20(key) diff --git a/src/crypto/chacha20poly1305.h b/src/crypto/chacha20poly1305.h index 75404ca5ffd..a6c3a668cfd 100644 --- a/src/crypto/chacha20poly1305.h +++ b/src/crypto/chacha20poly1305.h @@ -6,7 +6,7 @@ #define BITCOIN_CRYPTO_CHACHA20POLY1305_H #include -#include +#include #include #include diff --git a/src/crypto/hkdf_sha256_32.cpp b/src/crypto/hkdf_sha256_32.cpp index 81f3c1349a7..e62249446a4 100644 --- a/src/crypto/hkdf_sha256_32.cpp +++ b/src/crypto/hkdf_sha256_32.cpp @@ -1,11 +1,11 @@ -// Copyright (c) 2018-2019 The Bitcoin Core developers +// Copyright (c) 2018-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include -#include -#include +#include +#include CHKDF_HMAC_SHA256_L32::CHKDF_HMAC_SHA256_L32(const unsigned char* ikm, size_t ikmlen, const std::string& salt) { diff --git a/src/crypto/hkdf_sha256_32.h b/src/crypto/hkdf_sha256_32.h index d3735203005..f9f343b4b76 100644 --- a/src/crypto/hkdf_sha256_32.h +++ b/src/crypto/hkdf_sha256_32.h @@ -1,4 +1,4 @@ -// Copyright (c) 2018-2022 The Bitcoin Core developers +// Copyright (c) 2018-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -7,8 +7,8 @@ #include +#include #include -#include /** A rfc5869 HKDF implementation with HMAC_SHA256 and fixed key output length of 32 bytes (L=32) */ class CHKDF_HMAC_SHA256_L32 diff --git a/src/crypto/hmac_sha256.cpp b/src/crypto/hmac_sha256.cpp index 0ba99ae274f..034652064e5 100644 --- a/src/crypto/hmac_sha256.cpp +++ b/src/crypto/hmac_sha256.cpp @@ -1,10 +1,10 @@ -// Copyright (c) 2014-2018 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include -#include +#include CHMAC_SHA256::CHMAC_SHA256(const unsigned char* key, size_t keylen) { diff --git a/src/crypto/hmac_sha256.h b/src/crypto/hmac_sha256.h index abd731d1fe5..ea8cee88085 100644 --- a/src/crypto/hmac_sha256.h +++ b/src/crypto/hmac_sha256.h @@ -1,4 +1,4 @@ -// Copyright (c) 2014-2022 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -7,8 +7,8 @@ #include +#include #include -#include /** A hasher class for HMAC-SHA-256. */ class CHMAC_SHA256 diff --git a/src/crypto/hmac_sha512.cpp b/src/crypto/hmac_sha512.cpp index d70aee843bd..245ed29ec19 100644 --- a/src/crypto/hmac_sha512.cpp +++ b/src/crypto/hmac_sha512.cpp @@ -1,10 +1,10 @@ -// Copyright (c) 2014-2018 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include -#include +#include CHMAC_SHA512::CHMAC_SHA512(const unsigned char* key, size_t keylen) { diff --git a/src/crypto/hmac_sha512.h b/src/crypto/hmac_sha512.h index 8fa55d28444..d6bebc093c6 100644 --- a/src/crypto/hmac_sha512.h +++ b/src/crypto/hmac_sha512.h @@ -1,4 +1,4 @@ -// Copyright (c) 2014-2022 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -7,8 +7,8 @@ #include +#include #include -#include /** A hasher class for HMAC-SHA-512. */ class CHMAC_SHA512 diff --git a/src/crypto/muhash.h b/src/crypto/muhash.h index 5137c8e2400..f3409373236 100644 --- a/src/crypto/muhash.h +++ b/src/crypto/muhash.h @@ -8,7 +8,7 @@ #include #include -#include +#include class Num3072 { diff --git a/src/crypto/poly1305.cpp b/src/crypto/poly1305.cpp index 7fcbab4108d..c9c066b3097 100644 --- a/src/crypto/poly1305.cpp +++ b/src/crypto/poly1305.cpp @@ -1,11 +1,11 @@ -// Copyright (c) 2019 The Bitcoin Core developers +// Copyright (c) 2019-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include #include -#include +#include namespace poly1305_donna { diff --git a/src/crypto/poly1305.h b/src/crypto/poly1305.h index 94ea69be87e..494f7cdd4d8 100644 --- a/src/crypto/poly1305.h +++ b/src/crypto/poly1305.h @@ -8,8 +8,8 @@ #include #include +#include #include -#include #define POLY1305_BLOCK_SIZE 16 diff --git a/src/crypto/ripemd160.cpp b/src/crypto/ripemd160.cpp index a2f7c6e1563..1347bbb12d8 100644 --- a/src/crypto/ripemd160.cpp +++ b/src/crypto/ripemd160.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2014-2019 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -6,7 +6,7 @@ #include -#include +#include // Internal implementation code. namespace diff --git a/src/crypto/ripemd160.h b/src/crypto/ripemd160.h index fb631a66d2d..a06a3255e21 100644 --- a/src/crypto/ripemd160.h +++ b/src/crypto/ripemd160.h @@ -1,12 +1,12 @@ -// Copyright (c) 2014-2022 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_CRYPTO_RIPEMD160_H #define BITCOIN_CRYPTO_RIPEMD160_H +#include #include -#include /** A hasher class for RIPEMD-160. */ class CRIPEMD160 diff --git a/src/crypto/sha1.cpp b/src/crypto/sha1.cpp index 2610108f607..6dce204c894 100644 --- a/src/crypto/sha1.cpp +++ b/src/crypto/sha1.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2014-2019 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -6,7 +6,7 @@ #include -#include +#include // Internal implementation code. namespace diff --git a/src/crypto/sha1.h b/src/crypto/sha1.h index 741cdaad58b..fcb96ee6a72 100644 --- a/src/crypto/sha1.h +++ b/src/crypto/sha1.h @@ -1,12 +1,12 @@ -// Copyright (c) 2014-2022 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_CRYPTO_SHA1_H #define BITCOIN_CRYPTO_SHA1_H +#include #include -#include /** A hasher class for SHA1. */ class CSHA1 diff --git a/src/crypto/sha256.h b/src/crypto/sha256.h index b1348631d32..3ac771c5d0d 100644 --- a/src/crypto/sha256.h +++ b/src/crypto/sha256.h @@ -1,12 +1,12 @@ -// Copyright (c) 2014-2022 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_CRYPTO_SHA256_H #define BITCOIN_CRYPTO_SHA256_H +#include #include -#include #include /** A hasher class for SHA-256. */ diff --git a/src/crypto/sha256_avx2.cpp b/src/crypto/sha256_avx2.cpp index df8cb7a6c98..bfa54afa8ef 100644 --- a/src/crypto/sha256_avx2.cpp +++ b/src/crypto/sha256_avx2.cpp @@ -1,10 +1,10 @@ -// Copyright (c) 2017-2019 The Bitcoin Core developers +// Copyright (c) 2017-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifdef ENABLE_AVX2 -#include +#include #include #include diff --git a/src/crypto/sha256_sse4.cpp b/src/crypto/sha256_sse4.cpp index f68e226138e..d0a34934d80 100644 --- a/src/crypto/sha256_sse4.cpp +++ b/src/crypto/sha256_sse4.cpp @@ -1,12 +1,12 @@ -// Copyright (c) 2017-2022 The Bitcoin Core developers +// Copyright (c) 2017-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. // // This is a translation to GCC extended asm syntax from YASM code by Intel // (available at the bottom of this file). +#include #include -#include #if defined(__x86_64__) || defined(__amd64__) diff --git a/src/crypto/sha256_sse41.cpp b/src/crypto/sha256_sse41.cpp index d041fdfefc2..8a561d75e85 100644 --- a/src/crypto/sha256_sse41.cpp +++ b/src/crypto/sha256_sse41.cpp @@ -1,10 +1,10 @@ -// Copyright (c) 2018-2019 The Bitcoin Core developers +// Copyright (c) 2018-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifdef ENABLE_SSE41 -#include +#include #include #include diff --git a/src/crypto/sha256_x86_shani.cpp b/src/crypto/sha256_x86_shani.cpp index 74718281939..5ee957aaa78 100644 --- a/src/crypto/sha256_x86_shani.cpp +++ b/src/crypto/sha256_x86_shani.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2018-2022 The Bitcoin Core developers +// Copyright (c) 2018-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. // @@ -8,7 +8,7 @@ #if defined(ENABLE_SSE41) && defined(ENABLE_X86_SHANI) -#include +#include #include #include diff --git a/src/crypto/sha3.h b/src/crypto/sha3.h index 685586af63b..7a538e4a275 100644 --- a/src/crypto/sha3.h +++ b/src/crypto/sha3.h @@ -7,8 +7,8 @@ #include +#include #include -#include //! The Keccak-f[1600] transform. void KeccakF(uint64_t (&st)[25]); diff --git a/src/crypto/sha512.cpp b/src/crypto/sha512.cpp index 2713f06210e..338627fc5f7 100644 --- a/src/crypto/sha512.cpp +++ b/src/crypto/sha512.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2014-2022 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -6,7 +6,7 @@ #include -#include +#include // Internal implementation code. namespace diff --git a/src/crypto/sha512.h b/src/crypto/sha512.h index d2f7d6a05e4..102fa02a8cb 100644 --- a/src/crypto/sha512.h +++ b/src/crypto/sha512.h @@ -1,12 +1,12 @@ -// Copyright (c) 2014-2022 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_CRYPTO_SHA512_H #define BITCOIN_CRYPTO_SHA512_H +#include #include -#include /** A hasher class for SHA-512. */ class CSHA512 diff --git a/src/crypto/siphash.h b/src/crypto/siphash.h index c388c94951b..4c6a39e0b68 100644 --- a/src/crypto/siphash.h +++ b/src/crypto/siphash.h @@ -5,7 +5,7 @@ #ifndef BITCOIN_CRYPTO_SIPHASH_H #define BITCOIN_CRYPTO_SIPHASH_H -#include +#include #include #include diff --git a/src/init.cpp b/src/init.cpp index 77dc74f6901..d7a2a347e50 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -105,7 +105,7 @@ #include #ifndef WIN32 -#include +#include #include #endif diff --git a/src/interfaces/node.h b/src/interfaces/node.h index a17aa4afefc..a74695be85e 100644 --- a/src/interfaces/node.h +++ b/src/interfaces/node.h @@ -15,10 +15,10 @@ #include #include +#include +#include #include #include -#include -#include #include #include #include diff --git a/src/kernel/disconnected_transactions.cpp b/src/kernel/disconnected_transactions.cpp index f865fed688c..9667642a03d 100644 --- a/src/kernel/disconnected_transactions.cpp +++ b/src/kernel/disconnected_transactions.cpp @@ -1,10 +1,10 @@ -// Copyright (c) 2023 The Bitcoin Core developers +// Copyright (c) 2023-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include -#include +#include #include #include #include diff --git a/src/kernel/mempool_entry.h b/src/kernel/mempool_entry.h index 2adeaea652d..51a1f26642f 100644 --- a/src/kernel/mempool_entry.h +++ b/src/kernel/mempool_entry.h @@ -1,4 +1,4 @@ -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -15,11 +15,11 @@ #include #include +#include +#include #include #include #include -#include -#include class CBlockIndex; diff --git a/src/key_io.cpp b/src/key_io.cpp index 6cece47e410..3726d22233f 100644 --- a/src/key_io.cpp +++ b/src/key_io.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2014-2021 The Bitcoin Core developers +// Copyright (c) 2014-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -12,8 +12,8 @@ #include #include -#include -#include +#include +#include /// Maximum witness length for Bech32 addresses. static constexpr std::size_t BECH32_WITNESS_PROG_MAX_LEN = 40; diff --git a/src/netbase.h b/src/netbase.h index 3ac23050115..b2cc172e536 100644 --- a/src/netbase.h +++ b/src/netbase.h @@ -1,4 +1,4 @@ -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -11,9 +11,9 @@ #include #include +#include #include #include -#include #include #include #include diff --git a/src/node/connection_types.h b/src/node/connection_types.h index a911b95f7e9..a00895e2a8a 100644 --- a/src/node/connection_types.h +++ b/src/node/connection_types.h @@ -1,12 +1,12 @@ -// Copyright (c) 2022 The Bitcoin Core developers +// Copyright (c) 2022-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_NODE_CONNECTION_TYPES_H #define BITCOIN_NODE_CONNECTION_TYPES_H +#include #include -#include /** Different types of connections to a peer. This enum encapsulates the * information we have available at the time of opening or accepting the diff --git a/src/node/miner.h b/src/node/miner.h index 5073d69bb1b..a9a88b39cf2 100644 --- a/src/node/miner.h +++ b/src/node/miner.h @@ -1,5 +1,5 @@ // Copyright (c) 2009-2010 Satoshi Nakamoto -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -13,9 +13,9 @@ #include #include +#include #include #include -#include #include #include diff --git a/src/node/mini_miner.h b/src/node/mini_miner.h index aec2aaf6b6b..73143e829e7 100644 --- a/src/node/mini_miner.h +++ b/src/node/mini_miner.h @@ -1,4 +1,4 @@ -// Copyright (c) 2022 The Bitcoin Core developers +// Copyright (c) 2022-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -9,11 +9,11 @@ #include #include +#include #include #include #include #include -#include #include class CFeeRate; diff --git a/src/pow.h b/src/pow.h index ceba55d36a2..7ee1bddd3c3 100644 --- a/src/pow.h +++ b/src/pow.h @@ -1,5 +1,5 @@ // Copyright (c) 2009-2010 Satoshi Nakamoto -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -8,7 +8,7 @@ #include -#include +#include class CBlockHeader; class CBlockIndex; diff --git a/src/qt/bitcoin.h b/src/qt/bitcoin.h index 52b117eed7c..abc478bd456 100644 --- a/src/qt/bitcoin.h +++ b/src/qt/bitcoin.h @@ -1,4 +1,4 @@ -// Copyright (c) 2011-2022 The Bitcoin Core developers +// Copyright (c) 2011-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -10,7 +10,7 @@ #include #include -#include +#include #include #include diff --git a/src/qt/clientmodel.cpp b/src/qt/clientmodel.cpp index fb81dee8daa..dda26fa059b 100644 --- a/src/qt/clientmodel.cpp +++ b/src/qt/clientmodel.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2011-2022 The Bitcoin Core developers +// Copyright (c) 2011-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -23,7 +23,7 @@ #include #include -#include +#include #include #include diff --git a/src/qt/notificator.cpp b/src/qt/notificator.cpp index 13c082d2f0c..397d3ad88af 100644 --- a/src/qt/notificator.cpp +++ b/src/qt/notificator.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2011-2022 The Bitcoin Core developers +// Copyright (c) 2011-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -18,7 +18,7 @@ #ifdef USE_DBUS #include #include -#include +#include #endif #ifdef Q_OS_MACOS #include diff --git a/src/qt/optionsmodel.h b/src/qt/optionsmodel.h index c24b35ed793..4cbd5319229 100644 --- a/src/qt/optionsmodel.h +++ b/src/qt/optionsmodel.h @@ -1,4 +1,4 @@ -// Copyright (c) 2011-2022 The Bitcoin Core developers +// Copyright (c) 2011-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -12,7 +12,7 @@ #include #include -#include +#include #include struct bilingual_str; diff --git a/src/qt/transactiondesc.cpp b/src/qt/transactiondesc.cpp index 4d902f2cd28..db3c7f74176 100644 --- a/src/qt/transactiondesc.cpp +++ b/src/qt/transactiondesc.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2011-2022 The Bitcoin Core developers +// Copyright (c) 2011-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -19,7 +19,7 @@ #include #include -#include +#include #include #include diff --git a/src/qt/transactionrecord.cpp b/src/qt/transactionrecord.cpp index 5f9e37aac8e..4325c7f1582 100644 --- a/src/qt/transactionrecord.cpp +++ b/src/qt/transactionrecord.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2011-2022 The Bitcoin Core developers +// Copyright (c) 2011-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -9,7 +9,7 @@ #include #include -#include +#include #include diff --git a/src/rpc/blockchain.cpp b/src/rpc/blockchain.cpp index a237a24c84e..dd70c499fd7 100644 --- a/src/rpc/blockchain.cpp +++ b/src/rpc/blockchain.cpp @@ -1,5 +1,5 @@ // Copyright (c) 2010 Satoshi Nakamoto -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -52,7 +52,7 @@ #include #include -#include +#include #include #include diff --git a/src/rpc/blockchain.h b/src/rpc/blockchain.h index 954ede6519b..b42fe96fd30 100644 --- a/src/rpc/blockchain.h +++ b/src/rpc/blockchain.h @@ -1,4 +1,4 @@ -// Copyright (c) 2017-2022 The Bitcoin Core developers +// Copyright (c) 2017-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -13,7 +13,7 @@ #include #include -#include +#include #include class CBlock; diff --git a/src/rpc/client.cpp b/src/rpc/client.cpp index 08bd1142fce..0916c631c2f 100644 --- a/src/rpc/client.cpp +++ b/src/rpc/client.cpp @@ -1,5 +1,5 @@ // Copyright (c) 2010 Satoshi Nakamoto -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -7,8 +7,8 @@ #include #include +#include #include -#include #include #include diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp index aa68ae324dd..4fa62447af6 100644 --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -43,8 +43,8 @@ #include #include +#include #include -#include using interfaces::BlockRef; using interfaces::BlockTemplate; diff --git a/src/rpc/node.cpp b/src/rpc/node.cpp index 232a1d16f4e..a5da8785df4 100644 --- a/src/rpc/node.cpp +++ b/src/rpc/node.cpp @@ -1,5 +1,5 @@ // Copyright (c) 2010 Satoshi Nakamoto -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -26,7 +26,7 @@ #include #include -#include +#include #ifdef HAVE_MALLOC_INFO #include #endif diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp index 8f7b9769a8e..9c26e5c733c 100644 --- a/src/rpc/rawtransaction.cpp +++ b/src/rpc/rawtransaction.cpp @@ -42,8 +42,8 @@ #include #include +#include #include -#include #include diff --git a/src/rpc/server.h b/src/rpc/server.h index 5a22279a58e..d4b48f2418f 100644 --- a/src/rpc/server.h +++ b/src/rpc/server.h @@ -1,5 +1,5 @@ // Copyright (c) 2010 Satoshi Nakamoto -// Copyright (c) 2009-2021 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -9,9 +9,9 @@ #include #include +#include #include #include -#include #include #include diff --git a/src/streams.h b/src/streams.h index 1ebcff3671f..5a596047121 100644 --- a/src/streams.h +++ b/src/streams.h @@ -12,14 +12,14 @@ #include #include -#include +#include #include +#include #include +#include #include #include #include -#include -#include #include #include #include diff --git a/src/test/compress_tests.cpp b/src/test/compress_tests.cpp index 7e17e6ef939..7fefa467448 100644 --- a/src/test/compress_tests.cpp +++ b/src/test/compress_tests.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2012-2021 The Bitcoin Core developers +// Copyright (c) 2012-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -7,7 +7,7 @@ #include #include -#include +#include #include diff --git a/src/test/denialofservice_tests.cpp b/src/test/denialofservice_tests.cpp index 9ee7e9c9fe2..16fdd4b7b65 100644 --- a/src/test/denialofservice_tests.cpp +++ b/src/test/denialofservice_tests.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2011-2022 The Bitcoin Core developers +// Copyright (c) 2011-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -21,7 +21,7 @@ #include #include -#include +#include #include diff --git a/src/test/fuzz/addrman.cpp b/src/test/fuzz/addrman.cpp index dedea850803..a13945a5206 100644 --- a/src/test/fuzz/addrman.cpp +++ b/src/test/fuzz/addrman.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2020-2022 The Bitcoin Core developers +// Copyright (c) 2020-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -14,12 +14,12 @@ #include #include #include -#include #include #include #include #include +#include #include #include #include diff --git a/src/test/fuzz/asmap_direct.cpp b/src/test/fuzz/asmap_direct.cpp index 8a355fd3f60..1d693e5ecf5 100644 --- a/src/test/fuzz/asmap_direct.cpp +++ b/src/test/fuzz/asmap_direct.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2020-2021 The Bitcoin Core developers +// Copyright (c) 2020-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -10,7 +10,7 @@ #include #include -#include +#include FUZZ_TARGET(asmap_direct) { diff --git a/src/test/fuzz/cluster_linearize.cpp b/src/test/fuzz/cluster_linearize.cpp index fb4bf3a719f..6a1ea40aef3 100644 --- a/src/test/fuzz/cluster_linearize.cpp +++ b/src/test/fuzz/cluster_linearize.cpp @@ -6,16 +6,16 @@ #include #include #include -#include #include +#include #include #include #include #include -#include -#include +#include #include +#include using namespace cluster_linearize; diff --git a/src/test/fuzz/coinscache_sim.cpp b/src/test/fuzz/coinscache_sim.cpp index 6000d52fc97..30845c2ef9c 100644 --- a/src/test/fuzz/coinscache_sim.cpp +++ b/src/test/fuzz/coinscache_sim.cpp @@ -1,18 +1,18 @@ -// Copyright (c) 2023 The Bitcoin Core developers +// Copyright (c) 2023-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include #include #include -#include #include +#include #include -#include -#include +#include +#include #include -#include +#include #include namespace { diff --git a/src/test/fuzz/deserialize.cpp b/src/test/fuzz/deserialize.cpp index 270d546c394..05ca62b6fd0 100644 --- a/src/test/fuzz/deserialize.cpp +++ b/src/test/fuzz/deserialize.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2009-2021 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -29,10 +29,10 @@ #include #include +#include #include #include #include -#include using node::SnapshotMetadata; diff --git a/src/test/fuzz/feeratediagram.cpp b/src/test/fuzz/feeratediagram.cpp index 1a700987d67..6dcc63e91e2 100644 --- a/src/test/fuzz/feeratediagram.cpp +++ b/src/test/fuzz/feeratediagram.cpp @@ -2,7 +2,7 @@ // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. -#include +#include #include @@ -12,7 +12,7 @@ #include #include -#include +#include namespace { diff --git a/src/test/fuzz/txgraph.cpp b/src/test/fuzz/txgraph.cpp index 2c9fda9cd93..e4649970384 100644 --- a/src/test/fuzz/txgraph.cpp +++ b/src/test/fuzz/txgraph.cpp @@ -2,20 +2,20 @@ // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. -#include #include -#include #include +#include #include +#include #include #include #include +#include #include #include #include #include -#include #include using namespace cluster_linearize; diff --git a/src/test/fuzz/vecdeque.cpp b/src/test/fuzz/vecdeque.cpp index 9a71c43b987..30fc2da03f4 100644 --- a/src/test/fuzz/vecdeque.cpp +++ b/src/test/fuzz/vecdeque.cpp @@ -7,8 +7,8 @@ #include #include +#include #include -#include namespace { diff --git a/src/test/scriptnum10.h b/src/test/scriptnum10.h index 1381d5d431d..db66f3a14c9 100644 --- a/src/test/scriptnum10.h +++ b/src/test/scriptnum10.h @@ -1,15 +1,15 @@ // Copyright (c) 2009-2010 Satoshi Nakamoto -// Copyright (c) 2009-2021 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_TEST_SCRIPTNUM10_H #define BITCOIN_TEST_SCRIPTNUM10_H -#include +#include +#include #include #include -#include #include #include diff --git a/src/test/scriptnum_tests.cpp b/src/test/scriptnum_tests.cpp index 746d4d3c6b8..289a31da80a 100644 --- a/src/test/scriptnum_tests.cpp +++ b/src/test/scriptnum_tests.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2012-2020 The Bitcoin Core developers +// Copyright (c) 2012-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -7,8 +7,8 @@ #include #include -#include -#include +#include +#include BOOST_FIXTURE_TEST_SUITE(scriptnum_tests, BasicTestingSetup) diff --git a/src/test/serialize_tests.cpp b/src/test/serialize_tests.cpp index 9c68c8bb964..33a9133d2e2 100644 --- a/src/test/serialize_tests.cpp +++ b/src/test/serialize_tests.cpp @@ -8,7 +8,7 @@ #include #include -#include +#include #include #include diff --git a/src/test/util/cluster_linearize.h b/src/test/util/cluster_linearize.h index fa7945aac65..a89a46552b6 100644 --- a/src/test/util/cluster_linearize.h +++ b/src/test/util/cluster_linearize.h @@ -12,10 +12,10 @@ #include #include -#include +#include #include -#include #include +#include namespace { diff --git a/src/test/util/coins.cpp b/src/test/util/coins.cpp index 7e10c7c58d3..2dd98ae770f 100644 --- a/src/test/util/coins.cpp +++ b/src/test/util/coins.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2023 The Bitcoin Core developers +// Copyright (c) 2023-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -10,7 +10,7 @@ #include #include -#include +#include #include COutPoint AddTestCoin(FastRandomContext& rng, CCoinsViewCache& coins_view) diff --git a/src/txgraph.h b/src/txgraph.h index 9cfbe70acdc..5779397f82f 100644 --- a/src/txgraph.h +++ b/src/txgraph.h @@ -3,11 +3,11 @@ // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include +#include #include #include -#include -#include #include +#include #include diff --git a/src/txrequest.cpp b/src/txrequest.cpp index 5909146427b..03b4cd6b161 100644 --- a/src/txrequest.cpp +++ b/src/txrequest.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2020-2021 The Bitcoin Core developers +// Copyright (c) 2020-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -21,7 +21,7 @@ #include #include -#include +#include namespace { diff --git a/src/util/feefrac.h b/src/util/feefrac.h index c29dabc43b4..7577107e8c2 100644 --- a/src/util/feefrac.h +++ b/src/util/feefrac.h @@ -5,12 +5,13 @@ #ifndef BITCOIN_UTIL_FEEFRAC_H #define BITCOIN_UTIL_FEEFRAC_H -#include -#include -#include #include #include +#include +#include +#include + /** Data structure storing a fee and size, ordered by increasing fee/size. * * The size of a FeeFrac cannot be zero unless the fee is also zero. diff --git a/src/util/tokenpipe.cpp b/src/util/tokenpipe.cpp index 9425c62ebfc..c982fa6fc47 100644 --- a/src/util/tokenpipe.cpp +++ b/src/util/tokenpipe.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2021-2022 The Bitcoin Core developers +// Copyright (c) 2021-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include @@ -7,7 +7,7 @@ #ifndef WIN32 -#include +#include #include #include #include diff --git a/src/validation.h b/src/validation.h index d54794292ee..c7e70e3adbc 100644 --- a/src/validation.h +++ b/src/validation.h @@ -36,12 +36,12 @@ #include #include +#include #include #include #include #include #include -#include #include #include #include diff --git a/src/wallet/sqlite.cpp b/src/wallet/sqlite.cpp index 9b6215f9371..b902dd82c1d 100644 --- a/src/wallet/sqlite.cpp +++ b/src/wallet/sqlite.cpp @@ -10,15 +10,15 @@ #include #include #include -#include #include +#include #include #include #include #include -#include +#include #include #include #include diff --git a/src/wallet/test/wallet_tests.cpp b/src/wallet/test/wallet_tests.cpp index 966c6d2c4ba..1b0cfe2c4f5 100644 --- a/src/wallet/test/wallet_tests.cpp +++ b/src/wallet/test/wallet_tests.cpp @@ -1,12 +1,12 @@ -// Copyright (c) 2012-2022 The Bitcoin Core developers +// Copyright (c) 2012-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include +#include #include #include -#include #include #include diff --git a/src/wallet/walletdb.h b/src/wallet/walletdb.h index 507b79e7a35..5327a2cf691 100644 --- a/src/wallet/walletdb.h +++ b/src/wallet/walletdb.h @@ -1,18 +1,18 @@ // Copyright (c) 2009-2010 Satoshi Nakamoto -// Copyright (c) 2009-2022 The Bitcoin Core developers +// Copyright (c) 2009-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_WALLET_WALLETDB_H #define BITCOIN_WALLET_WALLETDB_H +#include #include