summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2016-10-27 15:37:34 +0200
committerGitHub <noreply@github.com>2016-10-27 15:37:34 +0200
commitcacbf8b32c7b910eeb6b8b5d37adf2a7dd2f343c (patch)
treefaddd5fb0ea8009db010f75c8bdff642ab5e4c2e /tests
parent38ad7400fa4ecc475b587456770e4d981dc9d037 (diff)
parent74c6500a30b99fde9af5d17a87723dcf18309964 (diff)
downloadNim-cacbf8b32c7b910eeb6b8b5d37adf2a7dd2f343c.tar.gz
Merge pull request #4963 from jangko/macro_error_improvement
Macro.error improvement fixes #4915
Diffstat (limited to 'tests')
-rw-r--r--tests/clearmsg/tmacroerrorproc.nim13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/clearmsg/tmacroerrorproc.nim b/tests/clearmsg/tmacroerrorproc.nim
new file mode 100644
index 000000000..9a6ff6a06
--- /dev/null
+++ b/tests/clearmsg/tmacroerrorproc.nim
@@ -0,0 +1,13 @@
+discard """
+  file: "tmacroerrorproc.nim"
+  line: 13
+  errormsg: "Expected a node of kind nnkCharLit, got nnkCommand"
+"""
+# issue #4915
+import macros
+
+macro mixer(n: typed): untyped =
+  expectKind(n, nnkCharLit)
+  
+mixer:
+  echo "owh"
\ No newline at end of file