Nim/tests/typerel/typedescs2.nim
Timothee Cour e40ff24c23
typeToString: type float => typedesc[float] (#17011)
* typeToString: type float => typedesc[float]

* fixup

* fix tests
2021-02-12 17:10:20 +01:00

17 lines
261 B
Nim

discard """
errormsg: "invalid type: 'typedesc[Table]' for const"
file: "typedescs2.nim"
line: 16
"""
# bug #9961
import typetraits
import tables
proc test(v: typedesc) =
echo v.type.name
# This crashes the compiler
const b: typedesc = Table
test b