Add a reset() method to CCounter that resets the value to 0, undoing all causally-prior increments.
This is not much harder than the current state-based counter implementation, and can probably written so it has minimal perf penalty if you never call reset().
Add a
reset()
method toCCounter
that resets the value to 0, undoing all causally-prior increments.This is not much harder than the current state-based counter implementation, and can probably written so it has minimal perf penalty if you never call
reset()
.