Nim is a statically typed compiled systems programming language. It combines successful concepts from mature languages like Python, Ada and Modula. Its design focuses on efficiency, expressiveness, and elegance (in that order of priority).
Error: type mismatch: got <int>
but expected one of:
proc withTypedesc(T: typedesc): T:type
first type mismatch at position: 1
required type for T: typedesc
but expression 'int' is of type: int
expression: withTypedesc(int)
Expected Output
none(int)
$ nim -v
Nim Compiler Version 1.6.6 [Windows: amd64]
Compiled at 2022-05-05
Copyright (c) 2006-2021 by Andreas Rumpf
active boot switches: -d:release
Example
https://play.nim-lang.org/#ix=4448
Current Output
Expected Output