summary refs log tree commit diff stats
path: root/lib
diff options
context:
space:
mode:
authorReimer Behrends <behrends@gmail.com>2014-07-23 03:20:50 +0200
committerReimer Behrends <behrends@gmail.com>2014-07-23 03:20:50 +0200
commit15734009ca9077cfc8c4139b8258b2db2d7492dd (patch)
treebf57ccd859e64dfd2bd86709585f903e33771a09 /lib
parentdcf1425eb996db5d39a23c0360573f1addd4a850 (diff)
downloadNim-15734009ca9077cfc8c4139b8258b2db2d7492dd.tar.gz
More robust implementation for finding the beginning of the stack.
This patch inserts an extra stack frame above the function that
calls the actual Nimrod code and ensures that a reference to this
frame is stored as the stack bottom.
Diffstat (limited to 'lib')
-rw-r--r--lib/system.nim6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/system.nim b/lib/system.nim
index 753205777..361e94462 100644
--- a/lib/system.nim
+++ b/lib/system.nim
@@ -2115,6 +2115,12 @@ when not defined(JS): #and not defined(NimrodVM):
         locals = addr(locals)
         setStackBottom(locals)
 
+    proc initStackBottomWith(locals: pointer) {.inline, compilerproc.} =
+      # We need to keep initStackBottom around for now to avoid
+      # bootstrapping problems.
+      when defined(setStackBottom):
+        setStackBottom(locals)
+
     var
       strDesc: TNimType
 
6-09-08 21:11:11 +0200 committer Dominik Picheta <dominikpicheta@gmail.com> 2016-09-08 21:11:11 +0200 Add Windows deploy stage to GitLab CI.' href='/ahoang/Nim/commit/.gitlab-ci.yml?h=devel&id=3e87ef35faa92333d6c78af1109d5da0cf0fc9c7'>3e87ef35f ^
cf40f3240 ^
e60868a78 ^
3e87ef35f ^




b790159bb ^
7e3ebc1bc ^





ef44c12a3 ^
97738a4f2 ^
7e3ebc1bc ^

3e87ef35f ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60