mirror of
https://github.com/nim-lang/Nim.git
synced 2026-02-19 01:18:32 +00:00
made macros.$ a bit smarter; but really this one needs to die
This commit is contained in:
@@ -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, "$"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user