summary refs log tree commit diff stats
path: root/tests/closure/tinvalidclosure2.nim
blob: 20e465c124642dee941c866ff8847eb0f100b308 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
discard """
  line: 10
  errormsg: "illegal capture 'A'"
"""

proc outer() = 
  var A: int

  proc ugh[T](x: T) {.cdecl.} =
    echo "ugha", A, x
    
  ugh[int](12)

outer()