diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2017-09-26 22:19:31 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2017-09-26 22:19:31 +0200 |
commit | 2bdbe97af1cd9046ba8028c5530e75025561afcc (patch) | |
tree | 416beac5ae9f26bb271e7d52ee89a847cdb24111 | |
parent | 61720e0df9475af647de171f6b2964c36234961a (diff) | |
download | Nim-2bdbe97af1cd9046ba8028c5530e75025561afcc.tar.gz |
workaround a GC/codegen issue that proves nasty to fix
-rw-r--r-- | compiler/vm.nim | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/compiler/vm.nim b/compiler/vm.nim index cb801bd5e..79bfb911d 100644 --- a/compiler/vm.nim +++ b/compiler/vm.nim @@ -66,7 +66,10 @@ proc stackTraceAux(c: PCtx; x: PStackFrame; pc: int; recursionLimit=100) = stackTraceAux(c, x.next, x.comesFrom, recursionLimit-1) var info = c.debug[pc] # we now use the same format as in system/except.nim - var s = toFilename(info) + var s = substr(toFilename(info), 0) + # this 'substr' prevents a strange corruption. XXX This needs to be + # investigated eventually but first attempts to fix it broke everything + # see the araq-wip-fixed-writebarrier branch. var line = toLinenumber(info) if line > 0: add(s, '(') |