summary refs log tree commit diff stats
path: root/tests/global/tglobal2.nim
blob: 73a575bbd297a4d83b9a852b41869d0f30ca6712 (plain) (blame)
1
2
3
4
5
6
7
8
9
# b.nim
import a_module
doAssert foo() == 0

proc hello(x: type) =
  var s {.global.} = default(x)
  doAssert s == 0

hello(int)