bitcoin/src/node
MacroFake 9eaef10801
Merge bitcoin/bitcoin#25707: refactor: Make const references to avoid unnecessarily copying objects and enable two clang-tidy checks
ae7ae36d31 tidy: Enable two clang-tidy checks (Aurèle Oulès)
081b0e53e3 refactor: Make const refs vars where applicable (Aurèle Oulès)

Pull request description:

  I added const references to some variables to avoid unnecessarily copying objects.

  Also added two clang-tidy checks : [performance-for-range-copy](https://releases.llvm.org/11.1.0/tools/clang/tools/extra/docs/clang-tidy/checks/performance-for-range-copy.html) and [performance-unnecessary-copy-initialization](https://releases.llvm.org/12.0.0/tools/clang/tools/extra/docs/clang-tidy/checks/performance-unnecessary-copy-initialization.html).

ACKs for top commit:
  vasild:
    ACK ae7ae36d31
  MarcoFalke:
    review ACK ae7ae36d31

Tree-SHA512: f6ac6b0cd0eee1e0c34d2f186484bc0f7ec6071451cccb33fa88a67d93d92b304e2fac378b88f087e94657745bca4e966dbc443759587400eb01b1f3061fde8c
2022-08-19 17:11:06 +02:00
..
blockstorage.cpp Merge bitcoin/bitcoin#25707: refactor: Make const references to avoid unnecessarily copying objects and enable two clang-tidy checks 2022-08-19 17:11:06 +02:00
blockstorage.h LoadMempool: Pass in load_path, stop using gArgs 2022-07-15 12:26:20 -04:00
caches.cpp Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
caches.h Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
chainstate.cpp refactor: Fix iwyu on node/chainstate 2022-07-21 20:23:23 +02:00
chainstate.h refactor: Fix iwyu on node/chainstate 2022-07-21 20:23:23 +02:00
coin.cpp Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
coin.h Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
connection_types.cpp [net] Move ConnectionType to its own file 2022-07-06 18:13:53 +02:00
connection_types.h [net] Move ConnectionType to its own file 2022-07-06 18:13:53 +02:00
context.cpp init: Initialize globals with kernel::Context's life 2022-06-02 11:40:03 -04:00
context.h kernel: Introduce empty and unused kernel::Context 2022-05-31 14:18:31 -04:00
eviction.cpp [net] Move eviction logic to its own file 2022-07-06 18:13:54 +02:00
eviction.h [net] Move eviction logic to its own file 2022-07-06 18:13:54 +02:00
interface_ui.cpp scripted-diff: Avoid incompatibility with CMake AUTOUIC feature 2022-06-14 10:38:51 +02:00
interface_ui.h scripted-diff: Avoid incompatibility with CMake AUTOUIC feature 2022-06-14 10:38:51 +02:00
interfaces.cpp Remove ::dustRelayFee 2022-08-02 15:26:49 +02:00
mempool_args.cpp scripted-diff: Move mempool_args to src/node 2022-08-02 15:31:01 +02:00
mempool_args.h scripted-diff: Move mempool_args to src/node 2022-08-02 15:31:01 +02:00
mempool_persist_args.cpp DumpMempool: Pass in dump_path, stop using gArgs 2022-07-15 11:30:50 -04:00
mempool_persist_args.h Move DEFAULT_PERSIST_MEMPOOL out of libbitcoinkernel 2022-07-15 12:26:20 -04:00
miner.cpp miner: Make mempool optional for BlockAssembler 2022-06-06 15:38:09 -04:00
miner.h miner: Make mempool optional for BlockAssembler 2022-06-06 15:38:09 -04:00
minisketchwrapper.cpp Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
minisketchwrapper.h Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
psbt.cpp Remove ::GetVirtualTransactionSize() alias 2022-08-02 15:27:20 +02:00
psbt.h Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
README.md doc: Remove irrelevant link to GitHub 2021-04-06 09:34:21 +02:00
transaction.cpp Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
transaction.h refactor: Remove defunct attributes.h includes 2022-05-21 13:54:33 -05:00
utxo_snapshot.h Add src/node/* code to node:: namespace 2022-01-06 22:14:16 -05:00
validation_cache_args.cpp validationcaches: Use size_t for sizes 2022-08-03 12:03:28 -04:00
validation_cache_args.h validationcaches: Add and use ValidationCacheSizes 2022-08-03 12:03:27 -04:00

src/node/

The src/node/ directory contains code that needs to access node state (state in CChain, CBlockIndex, CCoinsView, CTxMemPool, and similar classes).

Code in src/node/ is meant to be segregated from code in src/wallet/ and src/qt/, to ensure wallet and GUI code changes don't interfere with node operation, to allow wallet and GUI code to run in separate processes, and to perhaps eventually allow wallet and GUI code to be maintained in separate source repositories.

As a rule of thumb, code in one of the src/node/, src/wallet/, or src/qt/ directories should avoid calling code in the other directories directly, and only invoke it indirectly through the more limited src/interfaces/ classes.

This directory is at the moment sparsely populated. Eventually more substantial files like src/validation.cpp and src/txmempool.cpp might be moved there.