summary refs log tree commit diff stats
path: root/tests/destructor/tcustomseqs.nim
diff options
context:
space:
mode:
Diffstat (limited to 'tests/destructor/tcustomseqs.nim')
-rw-r--r--tests/destructor/tcustomseqs.nim14
1 files changed, 13 insertions, 1 deletions
diff --git a/tests/destructor/tcustomseqs.nim b/tests/destructor/tcustomseqs.nim
index a58602d46..97d7c07b6 100644
--- a/tests/destructor/tcustomseqs.nim
+++ b/tests/destructor/tcustomseqs.nim
@@ -8,7 +8,14 @@ discard """
 89
 90
 90
-after 1 1'''
+0 0 1
+0 1 2
+0 2 3
+1 0 4
+1 1 5
+1 2 6
+1 3 7
+after 6 6'''
   cmd: '''nim c --newruntime $file'''
 """
 
@@ -127,5 +134,10 @@ proc main =
   for i in 0 ..< s.len:
     echo s[i]
 
+  var nested = createSeq(createSeq(1, 2, 3), createSeq(4, 5, 6, 7))
+  for i in 0 ..< nested.len:
+    for j in 0 ..< nested[i].len:
+      echo i, " ", j, " ", nested[i][j]
+
 main()
 echo "after ", allocCount, " ", deallocCount