summary refs log tree commit diff stats
path: root/compiler/vm.nim
diff options
context:
space:
mode:
authorArne Döring <arne.doering@gmx.net>2017-06-02 01:22:21 +0200
committerAndreas Rumpf <rumpf_a@web.de>2017-06-02 01:22:21 +0200
commiteb8e267ff63eec0dd5279186a57d8af59f26c696 (patch)
treeae8c8ee6f5e7503372a47d3aed9e65995651203a /compiler/vm.nim
parentda52ade86e9df306b03958c5525a0e6973fc1cb5 (diff)
downloadNim-eb8e267ff63eec0dd5279186a57d8af59f26c696.tar.gz
improved comment satement support in macros (#5904)
Diffstat (limited to 'compiler/vm.nim')
-rw-r--r--compiler/vm.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/vm.nim b/compiler/vm.nim
index bc5873ff5..b8e6467b5 100644
--- a/compiler/vm.nim
+++ b/compiler/vm.nim
@@ -1406,7 +1406,7 @@ proc rawExecute(c: PCtx, start: int, tos: PStackFrame): TFullReg =
       if dest.kind in {nkStrLit..nkTripleStrLit} and
          regs[rb].kind in {rkNode}:
         dest.strVal = regs[rb].node.strVal
-      elif dest.kind == nkCommentStmt:
+      elif dest.kind == nkCommentStmt and regs[rb].kind in {rkNode}:
         dest.comment = regs[rb].node.strVal
       else:
         stackTrace(c, tos, pc, errFieldXNotFound, "strVal")