summary refs log tree commit diff stats
path: root/tests/destructor
diff options
context:
space:
mode:
Diffstat (limited to 'tests/destructor')
-rw-r--r--tests/destructor/tarc.nim14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/destructor/tarc.nim b/tests/destructor/tarc.nim
index 25921ffd7..d5e181630 100644
--- a/tests/destructor/tarc.nim
+++ b/tests/destructor/tarc.nim
@@ -100,4 +100,18 @@ mkManyLeaks()
 tsimpleClosureIterator()
 tleakingNewStmt()
 leakObjConstr()
+
+# bug #12964
+
+type
+  Token* = ref object of RootObj
+  Li* = ref object of Token
+
+proc bug12964*() =
+  var token = Li()
+  var tokens = @[Token()]
+  tokens.add token
+
+bug12964()
+
 echo getOccupiedMem() - startMem