chiark / gitweb /
lib/func.tcl, test/unit: Fix spin in `next-matching-date' and test.
[ca] / lib / func.tcl
index 1f73008200ba723c70a20dd9fe230040e492f5da..a3b58dc24e6caa61652f644f3d908d6b5ffddb1f 100644 (file)
@@ -326,7 +326,7 @@ proc next-matching-date* {pat refvar i} {
       {^\d+$} {
        ## A numeric literal.  If it's within bounds then set it; otherwise
        ## we'll have to start from the beginning.
-       if {$p < $n || $p > $max} { return step }
+       if {$p < $nn || $p > $max} { return step }
        set nn $p
       }