made macros.$ a bit smarter; but really this one needs to die
This commit is contained in:
parent
841a179d28
commit
6b3abdba0f
1 changed files with 2 additions and 0 deletions
|
|
@ -708,6 +708,8 @@ proc `$`*(node: NimNode): string {.compileTime.} =
|
|||
result = node.strVal
|
||||
of nnkSym:
|
||||
result = $node.symbol
|
||||
of nnkOpenSymChoice, nnkClosedSymChoice:
|
||||
result = $node[0]
|
||||
else:
|
||||
badNodeKind node.kind, "$"
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue