summary refs log tree commit diff stats
path: root/tests/pragmas/twarning_off.nim
diff options
context:
space:
mode:
authorAndrii Riabushenko <cdome@bk.ru>2019-07-25 23:07:43 +0100
committerAndrii Riabushenko <cdome@bk.ru>2019-07-25 23:07:43 +0100
commit95856ab8d3db88709c39c6809e81b8ea539b2e8b (patch)
tree13e1afde2b2dbf2902159f1a9d1fbc913917f863 /tests/pragmas/twarning_off.nim
parentd7bc4e43a2f571623cbc8e720eda072065320ffd (diff)
downloadNim-95856ab8d3db88709c39c6809e81b8ea539b2e8b.tar.gz
add test
Diffstat (limited to 'tests/pragmas/twarning_off.nim')
-rw-r--r--tests/pragmas/twarning_off.nim17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/pragmas/twarning_off.nim b/tests/pragmas/twarning_off.nim
new file mode 100644
index 000000000..1b86c6299
--- /dev/null
+++ b/tests/pragmas/twarning_off.nim
@@ -0,0 +1,17 @@
+discard """
+  nimout: '''
+compile start
+Hint: warn_module [Processing]
+Hint: hashes [Processing]
+warn_module.nim(4, 6) Hint: 'test' is declared but not used [XDeclaredButNotUsed]
+compile end
+'''
+"""
+
+static:
+  echo "compile start"
+
+import warn_module
+
+static:
+  echo "compile end"