summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2015-11-18 11:19:43 +0100
committerAraq <rumpf_a@web.de>2015-11-18 12:33:09 +0100
commitaad4ed776b56144a993bcb104d887ff69c9d3177 (patch)
treecd16075012178113d90c8dec1c306f792ba1dcee
parentedb495a6b36cd3a943a00a00652bf7a71b831e6f (diff)
downloadNim-aad4ed776b56144a993bcb104d887ff69c9d3177.tar.gz
allows macros to access documentation comments
-rw-r--r--compiler/vm.nim1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/vm.nim b/compiler/vm.nim
index 495b0c747..afc003452 100644
--- a/compiler/vm.nim
+++ b/compiler/vm.nim
@@ -1190,6 +1190,7 @@ proc rawExecute(c: PCtx, start: int, tos: PStackFrame): TFullReg =
       createStr regs[ra]
       let a = regs[rb].node
       if a.kind in {nkStrLit..nkTripleStrLit}: regs[ra].node.strVal = a.strVal
+      elif a.kind == nkCommentStmt: regs[ra].node.strVal = a.comment
       else: stackTrace(c, tos, pc, errFieldXNotFound, "strVal")
     of opcSlurp:
       decodeB(rkNode)