Use nano time for easier (and hopefully) faster checks/calculations. (#3323)

This commit is contained in:
Raja Subramanian
2025-01-12 00:56:46 +05:30
committed by GitHub
parent 28c39efa06
commit 53d300ba71
10 changed files with 130 additions and 127 deletions
+1 -1
View File
@@ -120,7 +120,7 @@ func (w *WrapAround[T, ET]) UndoUpdate(result WrapAroundUpdateResult[ET]) {
}
func (w *WrapAround[T, ET]) Rollover(val T, numCycles int) (result WrapAroundUpdateResult[ET]) {
if !w.initialized || numCycles < 0 {
if numCycles < 0 || !w.initialized {
return w.Update(val)
}