A first step (of a few) towards some source code reorganization, as well as making libbitcoinconsensus slightly more self contained.
Related to #15732.
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
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:
CAmount
MAX_MONEY
MoneyRange
Even 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.
ACK 2c1554a10940e471708d0d81bde0d490dc1c73b4.
I see the last two commits as a way to modernize amount.h
. Here are some additional suggestions:
typedef
nValue
/value
/ to follow our name conventionCAmount
as a non-reference parameter: s/const CAmount&
/CAmount
/. Also #23076 (comment).
Move amount.h to consensus/amount.h.
Renames, adds missing and removes uneeded includes.
concept ACK 9d0379cea6c164610d05287ae6dd4e66f35b92b 🏝
Signature:
0-----BEGIN PGP SIGNED MESSAGE-----
1Hash: SHA512
2
3concept ACK 9d0379cea6c164610d05287ae6dd4e66f35b92b 🏝
4-----BEGIN PGP SIGNATURE-----
5
6iQGzBAEBCgAdFiEE+rVPoUahrI9sLGYTzit1aX5ppUgFAlwqrYAACgkQzit1aX5p
7pUiIegv/UQSjhE3MlZkZ8Q9eV6M5sxc+xLMthzRmDDxQrktiXjsquDzCTLaKGrlA
826ASYaHNdvfTPn3UMY8IU2ibgI5EwRYgzOR4jWqlr7gBTU4DqQobi/oxxYrZPFTf
925Js5ET2yeIhCfusFwqorUXOI7zH/ehA7Om8re6zvWMyc3zMfDOCcI4+BCNF4Dbq
10aOWlS1j8GZaK7RtgUDCkk9z0gwZNTKfgJSDmWc7Lh1dsvawcOFAkF2nAZtwSfyxN
11//XU90+V0JMJz8sDkqBskidKi2tPi9j09ijqlo7ISBcA72skMzbBxLByo8nkZqv1
122D1OY/tqP6qDjhSwIb9OVf3/sWqRsMn5mz16yQ/KvhslyG8RY8ye8mYpFV6Xb7N3
13mWIiDgI15LcjsoNi1MBB2979OI3oNahxaVV9SjxUq8M8zsBGe2IT8mq4KdUunccf
140pCfiebUvJNg+/4pq+d6a3BA+tdzYP5MDNQ6xminkn0wVytxskD3mkD/Jck83nOu
15VVQPRV9w
16=KxXo
17-----END PGP SIGNATURE-----
Timestamp of file with hash fc451b85b7714b6efec31b9a07f211a521da7a434e0bfda8e649fdc21e55b2f6 -