Page MenuHomePhabricator

[refactor] make InvalidChainFound part of CChainState's implementation
ClosedPublic

Authored by majcosta on Sep 25 2020, 19:59.

Details

Summary

This is only called by other methods of CChainState so make it private.

Depends on D7440

Test Plan
ninja check check-functional

Diff Detail

Repository
rABC Bitcoin ABC
Branch
make_invalidchain_cchainstate
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 12932
Build 25931: Build Difflint-circular-dependencies · build-without-wallet · build-diff · build-clang-10 · build-clang-tidy
Build 25930: arc lint + arc unit

Event Timeline

deadalnix requested changes to this revision.Sep 25 2020, 22:38
deadalnix added a subscriber: deadalnix.

I don't see how that helps? If doesn't look like it needs to access local state of the function, so making is static is better.

Unless you have some plan to move the state it uses, like pindexBestInvalid into CChainState ?

In which case, you need to provide a rationale for this refactoring.

This revision now requires changes to proceed.Sep 25 2020, 22:38
This revision is now accepted and ready to land.Sep 25 2020, 22:52