summary refs log tree commit diff stats
path: root/compiler/transf.nim
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2017-02-16 00:43:14 +0100
committerAraq <rumpf_a@web.de>2017-02-16 11:15:43 +0100
commit71026cec6e28d89677be0b5b3db4f8f79ee4bb3e (patch)
tree73bdf98c023f3f13b93ace22a63e1bb47035a213 /compiler/transf.nim
parent8de6c39f87be3afa0b997a80b9124e42e4741d73 (diff)
downloadNim-71026cec6e28d89677be0b5b3db4f8f79ee4bb3e.tar.gz
fixes #5383
Diffstat (limited to 'compiler/transf.nim')
-rw-r--r--compiler/transf.nim5
1 files changed, 4 insertions, 1 deletions
diff --git a/compiler/transf.nim b/compiler/transf.nim
index 13c6dd8fe..cbd1f15e3 100644
--- a/compiler/transf.nim
+++ b/compiler/transf.nim
@@ -869,7 +869,10 @@ proc transform(c: PTransf, n: PNode): PTransNode =
     else:
       result = transformSons(c, n)
   of nkIdentDefs, nkConstDef:
-    result = transformSons(c, n)
+    result = n.PTransNode
+    #transformSons(c, n)
+    let L = n.len-1
+    result[L] = transform(c, n.sons[L])
     # XXX comment handling really sucks:
     if importantComments():
       PNode(result).comment = n.comment