Merge bitcoin/bitcoin#34308: doc: Document IWYU workaround

03f363d378 doc: Document IWYU workaround (Hennadii Stepanov)

Pull request description:

  This PR addresses the following comments:
  - https://github.com/bitcoin/bitcoin/pull/34079#discussion_r2640003086:
    > it would be good to reduce and report this bug upstream. Otherwise, wide-spread use of iwyu in this code-base seems risky.

  - https://github.com/bitcoin/bitcoin/pull/34079#discussion_r2640035350:
    > Would have been good if it was documented, rather than adding undocumented workarounds for buggy tools.

ACKs for top commit:
  maflcko:
    lgtm ACK 03f363d378
  sedited:
    ACK 03f363d378

Tree-SHA512: 160a963c07f853995c8b4741a6ccca1d8431a576c760fca082116cebde4d133f7c8ec51f09e8f85f54428f86bad2635e1bd708177eecf71feb0bf1489f1e2b3e
This commit is contained in:
merge-script
2026-01-20 09:51:42 +00:00

View File

@@ -10,6 +10,9 @@
#include <consensus/consensus.h>
#include <consensus/validation.h>
#include <key_io.h>
// IWYU incorrectly suggests replacing this header
// with forward declarations.
// See https://github.com/include-what-you-use/include-what-you-use/issues/1886.
#include <primitives/block.h> // IWYU pragma: keep
#include <primitives/transaction.h>
#include <script/descriptor.h>