summary refs log tree commit diff stats
path: root/tests/global/a_module.nim
diff options
context:
space:
mode:
Diffstat (limited to 'tests/global/a_module.nim')
-rw-r--r--tests/global/a_module.nim6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/global/a_module.nim b/tests/global/a_module.nim
new file mode 100644
index 000000000..1d3f4848c
--- /dev/null
+++ b/tests/global/a_module.nim
@@ -0,0 +1,6 @@
+# a.nim
+{.push stackTrace: off.}
+proc foo*(): int =
+  var a {.global.} = 0
+  result = a
+{.pop.}
\ No newline at end of file