Page MenuHomePhabricator

[refactor] move Park and InvalidateBlock to CChainState public API
ClosedPublic

Authored by majcosta on Aug 17 2020, 19:27.

Details

Summary

Future PR16849 (D7204) introduces locking m_cs_chainstate to their version of InvalidateBlock. Our codepath for that is shared by ParkBlock, InvalidateBlock and FinalizeBlock, so having all three be members of CChainState (FinalizeBlock already is) makes sense.

Also made UnwindBlock private since it's not supposed to be called by just anyone, rather by stuff that knows what they're doing -, and moved FinalizeBlock implementation to be closer to the other two since that makes more sense.

Test Plan
cmake .. -DCMAKE_BUILD_TYPE=Debug -GNinja
ninja check check-functional

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

[Bot Message]
One or more PR numbers were detected in the summary.
Links to those PRs have been inserted into the summary for reference.

removing from the queue until dependencies are on Phab and the big picture makes sense

This revision is now accepted and ready to land.Aug 17 2020, 22:14