Nim/tests/errmsgs/t10489_b.nim
Neelesh Chandola 7ebb2baa6c Assigning template to var/let/const gives a proper error (#12851)
* Assigning template to var/let/const gives a proper error

* Fix style
2019-12-09 08:19:40 +00:00

9 lines
167 B
Nim

discard """
errormsg: "cannot assign macro 'm' to 'x2'. Did you mean to call the macro with '()'?"
line: 9
"""
macro m(body: untyped): untyped =
body
const x2 = m