summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorReimer Behrends <behrends@gmail.com>2014-11-06 02:09:51 +0100
committerReimer Behrends <behrends@gmail.com>2014-11-06 02:09:51 +0100
commitead00d2328507b3ee70f3d49a74d94d946729e14 (patch)
treebed97aef2bc33e7e49826648d91b00d25d57a6a6
parentee9c70e0348b0586d69faa06d2ed1655bb216a6a (diff)
downloadNim-ead00d2328507b3ee70f3d49a74d94d946729e14.tar.gz
Properly initialize the stack with emulated thread variables.
-rw-r--r--compiler/cgen.nim3
1 files changed, 1 insertions, 2 deletions
diff --git a/compiler/cgen.nim b/compiler/cgen.nim
index afeac8c88..8e20ba654 100644
--- a/compiler/cgen.nim
+++ b/compiler/cgen.nim
@@ -1061,8 +1061,7 @@ proc genMainProc(m: BModule) =
     gBreakpoints.app(m.genFilenames)
   
   let initStackBottomCall =
-    if emulatedThreadVars() or
-      platform.targetOS == osStandalone: "".toRope
+    if platform.targetOS == osStandalone: "".toRope
     else: ropecg(m, "\t#initStackBottomWith((void *)&inner);$N")
   inc(m.labels)
   appcg(m, m.s[cfsProcs], PreMainBody, [