DisconnectBlock currently has a complicated interface which returns a different result based on whether pfClean was passed or not. Change this to return a tristate enum instead. As an added bonus, remove the ValidationState& argument which was unused.
Simplify DisconnectBlock arguments/return value #10297
pull sipa wants to merge 1 commits into bitcoin:master from sipa:disconnect_enum changing 1 files +33 −26-
sipa commented at 11:16 PM on April 28, 2017: member
-
db994b2de9
Simplify DisconnectBlock arguments/return value
DisconnectBlock currently has a complicated interface: Situation Return value pfClean != nullptr pfClean == nullptr All good: true true Failure: false false Unclean rewind: true false with *pfClean=false Change this to return a tristate enum instead. As an added bonus, remove the ValidationState& argument which was unused. - fanquake added the label Validation on Apr 28, 2017
- dcousens approved
-
kallewoof commented at 7:31 AM on May 1, 2017: member
utACK db994b2de93f52c9e7bed8529ca925de5064a46f
-
TheBlueMatt commented at 5:11 PM on May 1, 2017: member
utACK db994b2de93f52c9e7bed8529ca925de5064a46f
- sdaftuar approved
-
sdaftuar commented at 5:24 PM on May 1, 2017: member
utACK db994b2de93f52c9e7bed8529ca925de5064a46f, this is much better
Would be nice to add a unit test for these return values at some point
- sipa merged this on May 3, 2017
- sipa closed this on May 3, 2017
- sipa referenced this in commit 431a548faa on May 3, 2017
- sipa deleted the branch on Jun 23, 2017
- codablock referenced this in commit fd4af51ee3 on Sep 27, 2017
- codablock referenced this in commit 1a138d66ab on Oct 12, 2017
- codablock referenced this in commit 9a266e68d0 on Oct 24, 2017
- UdjinM6 referenced this in commit e25e4c928c on Nov 8, 2017
- ryan-shaw referenced this in commit f261200b4d on Feb 21, 2018
- ryan-shaw referenced this in commit fecb499989 on Feb 21, 2018
- PastaPastaPasta referenced this in commit 432012cee2 on Jun 10, 2019
- MarcoFalke locked this on Sep 8, 2021
Contributors
Labels