mirror of
https://github.com/nim-lang/Nim.git
synced 2026-01-02 03:02:31 +00:00
macros.$ can now turn a nnkSym into a string.
This commit is contained in:
@@ -649,6 +649,8 @@ proc `$`*(node: PNimrodNode): string {.compileTime.} =
|
||||
result = $node.basename.ident & "*"
|
||||
of nnkStrLit..nnkTripleStrLit:
|
||||
result = node.strVal
|
||||
of nnkSym:
|
||||
result = $node.symbol
|
||||
else:
|
||||
badNodeKind node.kind, "$"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user