add test for shallow seq copy

currently looks like it's not covered
This commit is contained in:
Jacek Sieka
2016-03-23 22:29:28 +08:00
parent d1b2c35897
commit 266e40f27e

17
tests/seq/tshallowseq.nim Normal file
View File

@@ -0,0 +1,17 @@
discard """
output: '''@[1, 42, 3]
@[1, 42, 3]
'''
"""
proc xxx() =
var x: seq[int] = @[1, 2, 3]
var y: seq[int]
system.shallowCopy(y, x)
y[1] = 42
echo y
echo x
xxx()