summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
authorYuriy Glukhov <yglukhov@users.noreply.github.com>2017-07-30 12:10:07 +0300
committerAndreas Rumpf <rumpf_a@web.de>2017-07-30 11:10:07 +0200
commit8481e9ff14f39dab98c65e4c618fb8a847444b7d (patch)
treed527634d0f73dc55e06edb04637c26437278cd34 /tests
parent670d63a3318533f7d7e7d1cedc88cb7f8f6cb11a (diff)
downloadNim-8481e9ff14f39dab98c65e4c618fb8a847444b7d.tar.gz
Fixed NimTypeKind enum, added missing values. (#6157)
Diffstat (limited to 'tests')
-rw-r--r--tests/macros/tgettype.nim7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/macros/tgettype.nim b/tests/macros/tgettype.nim
index 8b787b022..fa02bce57 100644
--- a/tests/macros/tgettype.nim
+++ b/tests/macros/tgettype.nim
@@ -18,3 +18,10 @@ macro testGeneric(T: typedesc[Model]): string=
 
 echo testUser
 echo User.testGeneric
+
+macro assertVoid(e: typed): untyped =
+  assert(getTypeInst(e).typeKind == ntyVoid)
+
+proc voidProc() = discard
+
+assertVoid voidProc()