This commit is contained in:
Araq 2017-02-16 00:43:14 +01:00
commit 97e26967f1
11 changed files with 60 additions and 17 deletions

View file

@ -19,3 +19,16 @@ proc foo(): void =
echo repr(v1 *** v2)
foo()
# bug #5383
import sequtils
proc zipWithIndex[A](ts: seq[A]): seq[(int, A)] =
toSeq(pairs(ts))
proc main =
discard zipWithIndex(@["foo", "bar"])
discard zipWithIndex(@[1, 2])
discard zipWithIndex(@[true, false])
main()