HomePhabricator

refactoring: add a method for determining if a block is pruned or not

Description

refactoring: add a method for determining if a block is pruned or not

Summary:
"The check for whether a block is pruned or not is sufficiently obscure that it deserves a macro. It is also used in 2 places, with more coming, e.g. #10757 (turns out it was a move, not an addition)."

This is a backport from Core PR13259: https://github.com/bitcoin/bitcoin/pull/13259

Test Plan:

ninja check
./test/functional/test_runner.py

Reviewers: O1 Bitcoin ABC, #bitcoin_abc, deadalnix, nakihito, jasonbcox

Reviewed By: O1 Bitcoin ABC, #bitcoin_abc, deadalnix, nakihito, jasonbcox

Subscribers: jasonbcox

Differential Revision: https://reviews.bitcoinabc.org/D4624

Details

Provenance
Wladimir J. van der Laan <laanwj@gmail.com>Authored on Jun 8 2018, 11:31
majcostaCommitted on Dec 5 2019, 00:05
nakihitoPushed on Dec 5 2019, 00:32
Reviewer
Restricted Owners Package
Differential Revision
D4624: refactoring: add a method for determining if a block is pruned or not
Parents
rSTAGING5b53e81f29d6: Integrate gArgs and chainparams into the Seeder
Branches
Unknown
Tags
Unknown
References
tag: phabricator/base/14637, tag: phabricator/base/14635