Deques compilation error fix (#5591)

This commit is contained in:
Dmitriy Fomichev
2017-03-24 02:09:51 +03:00
committed by Andreas Rumpf
parent d4b4cad4ea
commit 268a1f7cfd
2 changed files with 19 additions and 2 deletions

View File

@@ -0,0 +1,17 @@
discard """
output: '''true'''
"""
import deques
proc index(self: Deque[int], idx: Natural): int =
self[idx]
proc main =
var testDeque = initDeque[int]()
testDeque.addFirst(1)
assert testDeque.index(0) == 1
main()
echo "true"