A first step (of a few) towards some source code reorganization, as well as making libbitcoinconsensus slightly more self contained.
Related to #15732.
<!--e57a25ab6845829454e8d69fc972939a-->
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
<!--174a7506f384e20aa4161008e828411d-->
Reviewers, this pull request conflicts with the following ones:
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.
Concept ACK. I think this is organizationally the right thing to do. Nearly everything in amount.h is consensus critical:
CAmountMAX_MONEYMoneyRangeEven COIN, though it strictly is a presentation detail, is used in src/validation.cpp to set the initial subsidy. So changing it would be consensus critical.
Concept ACK.
ACK 2c1554a10940e471708d0d81bde0d490dc1c73b4.
I see the last two commits as a way to modernize amount.h. Here are some additional suggestions:
typedefnValue/value/ to follow our name conventionCAmount as a non-reference parameter: s/const CAmount&/CAmount/. Also #23076 (comment).Concept ACK
Move amount.h to consensus/amount.h.
Renames, adds missing and removes uneeded includes.
concept ACK 9d0379cea6c164610d05287ae6dd4e66f35b92b 🏝
<details><summary>Show signature and timestamp</summary>
Signature:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
concept ACK 9d0379cea6c164610d05287ae6dd4e66f35b92b 🏝
-----BEGIN PGP SIGNATURE-----
iQGzBAEBCgAdFiEE+rVPoUahrI9sLGYTzit1aX5ppUgFAlwqrYAACgkQzit1aX5p
pUiIegv/UQSjhE3MlZkZ8Q9eV6M5sxc+xLMthzRmDDxQrktiXjsquDzCTLaKGrlA
26ASYaHNdvfTPn3UMY8IU2ibgI5EwRYgzOR4jWqlr7gBTU4DqQobi/oxxYrZPFTf
25Js5ET2yeIhCfusFwqorUXOI7zH/ehA7Om8re6zvWMyc3zMfDOCcI4+BCNF4Dbq
aOWlS1j8GZaK7RtgUDCkk9z0gwZNTKfgJSDmWc7Lh1dsvawcOFAkF2nAZtwSfyxN
//XU90+V0JMJz8sDkqBskidKi2tPi9j09ijqlo7ISBcA72skMzbBxLByo8nkZqv1
2D1OY/tqP6qDjhSwIb9OVf3/sWqRsMn5mz16yQ/KvhslyG8RY8ye8mYpFV6Xb7N3
mWIiDgI15LcjsoNi1MBB2979OI3oNahxaVV9SjxUq8M8zsBGe2IT8mq4KdUunccf
0pCfiebUvJNg+/4pq+d6a3BA+tdzYP5MDNQ6xminkn0wVytxskD3mkD/Jck83nOu
VVQPRV9w
=KxXo
-----END PGP SIGNATURE-----
Timestamp of file with hash fc451b85b7714b6efec31b9a07f211a521da7a434e0bfda8e649fdc21e55b2f6 -
</details>