Nim/tests/ccgbugs/tnocodegen_for_compiletime.nim
Arne Döring f94ec363ab Allow void macro result (#11286)
* allow void macro result
* add test for void macro result type
2019-05-21 21:31:40 +02:00

9 lines
197 B
Nim

# bug #1679
import macros, tables, hashes
proc hash(v: NimNode): Hash = 4 # performance is for suckers
macro test(body: untyped) =
var a = initCountTable[NimNode]()
a.inc(body)
test:
1 + 1