refactor: avoid unreachable throw in inline_check_non_fatal #34426

pull lisenokdonbassenok wants to merge 1 commits into bitcoin:master from lisenokdonbassenok:refactor/util-inline-check-non-fatal changing 1 files +2 −1
  1. lisenokdonbassenok commented at 6:49 am on January 28, 2026: none
    In builds where G_ABORT_ON_FAILED_ASSUME is true, inline_check_non_fatal called assertion_fail() and then had a throw NonFatalCheckError that was never reachable, because assertion_fail() either aborts or throws and never returns. Refactored inline_check_non_fatal to use if constexpr (G_ABORT_ON_FAILED_ASSUME) { assertion_fail(...) } else { throw NonFatalCheckError(...) } branch, removing the unreachable throw
  2. refactor: avoid unreachable throw in `inline_check_non_fatal` e8e714db33
  3. DrahtBot added the label Refactoring on Jan 28, 2026
  4. DrahtBot commented at 6:49 am on January 28, 2026: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/34426.

    Reviews

    See the guideline for information on the review process. A summary of reviews will appear here.

  5. maflcko commented at 6:55 am on January 28, 2026: member

    Thank you for your contribution. While this stylistic change can make sense on its own, it comes at a cost and risk for the project as a whole. The weak motivation for the change does not justify the burden that it places on the project. A burden could be any of the following:

    • Time spent on review
    • Accidental introduction of bugs
    • (Silent) merge conflicts, either in the branch or a backport branch. Those conflicts demand further developer and reviewer time or introduce bugs.

    Generally, if the style is not mentioned nor enforced by the developer notes, we leave it up to the original author to pick whatever fits them best personally and then leave it that way until the line is touched for other reasons.

    If you wish to contribute in the future, please focus on creating high-quality, original content that demonstrates a clear understanding of the project’s requirements and goals. Also, see the contributing guidelines.

    Leave a comment below, if you have any questions.

  6. maflcko closed this on Jan 28, 2026


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-02-11 21:13 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me