tinvalidclosure3.nim 169 B

12345678910111213
  1. discard """
  2. errormsg: "illegal capture 'x'"
  3. line: 9
  4. """
  5. proc outer(arg: string) =
  6. var x = 0
  7. proc inner {.inline.} =
  8. echo "inner", x
  9. inner()
  10. outer("abc")