We don’t add or maintain these, and they are of little value, as well as having the effect of polluting diffs, if changed.
They are also wrong, i.e DEFAULT_SCRIPTCHECK_THREADS
is not in
validation.h
.
We don’t add or maintain these, and they are of little value, as well as having the effect of polluting diffs, if changed.
They are also wrong, i.e DEFAULT_SCRIPTCHECK_THREADS
is not in
validation.h
.
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/32562.
See the guideline for information on the review process.
Type | Reviewers |
---|---|
ACK | stickies-v, willcl-ark, fjahr |
Concept ACK | Sjors |
If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.
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.
9@@ -10,10 +10,10 @@
10 #include <span.h>
11
12 #include <algorithm>
13-#include <array> // For std::begin and std::end.
14+#include <array>
15 #include <bit>
16-
17-#include <stdint.h>
18+#include <cstdint>
3cf3695910f332f1aa8af57de7a01f63d5d7dc68: maybe change this in a separate commit?
Similar in other files, or is this auto generated?
Concept ACK
Do we have a linter for unused includes?
No opinion on the seemingly unrelated WIN32
changes.
Do we have a linter for unused includes?
No includes are being removed here, so I don’t see how that’s relevant? IWYU would be the closest tool you could run.
Concept ACK.
https://github.com/bitcoin/bitcoin/blob/ff1ee102c4babadd85e4a18234061f10daaa119d/src/validationinterface.h#L11 https://github.com/bitcoin/bitcoin/blob/ff1ee102c4babadd85e4a18234061f10daaa119d/src/cuckoocache.h#L10
The only others I found were in subtrees.
Concept ACK
I kind of like the idea but seems way too much effort to actually maintain this in a consistent way for very little gain. I don’t remember if any of these ever saved me time, probably not because my workflow doesn’t rely on them and most people probably use an editor that allows them to jump to definition.
Do we have a linter for unused includes?
No includes are being removed here, so I don’t see how that’s relevant? IWYU would be the closest tool you could run.
The comments were useful for knowing when an include could be dropped (though not if they’re incomplete).
12-#include <sys/resource.h> // for getrlimit
13-#include <limits.h> // for PAGESIZE
14-#include <unistd.h> // for sysconf
15+#include <sys/mman.h>
16+#include <sys/resource.h>
17+#include <limits.h>
#include <limits.h>
can be removed according to IWYU I suspect because we also #include <limits>
14+#include <array>
15 #include <bit>
16-
17-#include <stdint.h>
18+#include <cstdint>
19+#include <span>
span.h
include can now be removed according to IWYU
25@@ -26,12 +26,13 @@
26
27 #include <array>
28 #include <cmath>
29+#include <cstdint>
30+#include <cstring>
cstring
includes can just be dropped according to IWYU
ACK e4aee0b3a23a9609e16bd7c8eda618dcf0a8b1db
The new includes seem arbitrary, they usually still don’t represent the full include list (according to IWYU), and could be dropped, but I verified them against the IWYU run and mostly seem fine (I added comments for the ones that seem incorrect.
Found a couple more include comments in util/fs_helpers.cpp
We don't add or maintain these, and they are of little value, as
well as having the effect of polluting diffs.
They are also wrong, i.e DEFAULT_SCRIPTCHECK_THREADS is not in
validation.h.
ACK 7193245cd66791216d4e586ca09302b26d4b7528
Confirmed there are no such comments left outside of subtrees. Also seeing different full include lists suggested by IWYU but those seem exaggerated for this change here. Checked a hand full of the files that had bigger changes and didn’t find anything wrong.