summary refs log tree commit diff stats
path: root/tests/generics/tarc_misc.nim
blob: 3e77625565925aa2aab55e0ef7d7156e0002751d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
discard """
  output: ''''''
  cmd: "nim c --gc:arc $file"
"""

# bug #13519

var unrelated: seq[proc() {.closure, gcsafe.}]

unrelated.add proc () =
  echo "gcsafe"

import tables, sequtils
let t = newTable[int, proc()]()

type
  MyProc = proc() {.closure.}

var result: seq[MyProc] = @[]
for x in t.values:
  result.add(x)