You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The contract on self.start(10) would not hold. (This is true even if this were an upcounting timer and the final count were updated by self.start(10) , as the timer count has already increased.)
The text was updated successfully, but these errors were encountered:
Thank you for opening this issue, @droogmic. I agree with your interpretation, and the timer restarting is certainly the most sensible actions for the uses cases that I've seen so far.
I'd like to leave this open for a while to see if there are any disagreements, but from my perspective, it seems the correct action is to update the documentation of CountDown::start to clearly state that the documented contract implies a restart.
The countdown trait states:
The effect of calling start a second time is unclear.
One interpretation is that the countdown restarts; consider a countdown that does not restart (possibly because cancel has not been called):
The contract on
self.start(10)
would not hold. (This is true even if this were an upcounting timer and the final count were updated byself.start(10)
, as the timer count has already increased.)The text was updated successfully, but these errors were encountered: