Files
bitcoin/src/kernel
merge-script 908cc9d30b Merge bitcoin/bitcoin#35344: kernel: improve BITCOINKERNEL_WARN_UNUSED_RESULT usage
18c1cc65e9 kernel: improve BITCOINKERNEL_WARN_UNUSED_RESULT usage (stickies-v)

Pull request description:

  Similar to `[[nodiscard]]`, `BITCOINKERNEL_WARN_UNUSED_RESULT` is used to indicate that ignoring a function's return value is almost certainly a bug.

  It is used in cases such as a resource leak (e.g. an owning handle returned by a `*_create` or `*_copy` function), or when the returned value is itself an error/status code. It is not used merely because discarding the result is wasteful, e.g. on getters or predicates.

  Fix the incorrect usage, and properly document the attribute. Having this clearly documented helps avoid bikeshedding on future PRs.

ACKs for top commit:
  w0xlt:
    ACK 18c1cc65e9
  stringintech:
    ACK 18c1cc65
  sedited:
    ACK 18c1cc65e9

Tree-SHA512: ba5aa19f0b90ef12ed3c200449734d9aa67af166f2a2b29e321d3ec1e9b49483215c5078ae1dd945ea65650a2017f3101bf75abcc9d3388eb1a3d4c8070c22dd
2026-05-22 09:47:42 +02:00
..