summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2014-08-31 02:45:32 +0200
committerAraq <rumpf_a@web.de>2014-08-31 02:45:32 +0200
commit31db3aeadefb73831b4fa27b1a1118acd5aa6134 (patch)
treedf1d4fd92f195bded0c746deb69f0403079b1f41
parentd3a7fa20ae743414cfe0f0874061d5a694180eff (diff)
downloadNim-31db3aeadefb73831b4fa27b1a1118acd5aa6134.tar.gz
minor bugfix for void .compileTime procs
-rw-r--r--compiler/semexprs.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/semexprs.nim b/compiler/semexprs.nim
index e2d05e15d..a397993d8 100644
--- a/compiler/semexprs.nim
+++ b/compiler/semexprs.nim
@@ -662,7 +662,7 @@ proc evalAtCompileTime(c: PContext, n: PNode): PNode =
 
   # optimization pass: not necessary for correctness of the semantic pass
   if {sfNoSideEffect, sfCompileTime} * callee.flags != {} and
-     {sfForward, sfImportc} * callee.flags == {}:
+     {sfForward, sfImportc} * callee.flags == {} and n.typ != nil:
     if sfCompileTime notin callee.flags and 
         optImplicitStatic notin gOptions: return