> (heap overlaps stack, so one function jump outside one's bound). That seems very improbably. It's more likely that you have a stack overflow and while writing a stack variable you also overwrite the return instructions of your function.
Is your code open-source? If you compile your code with: * `-d:useMalloc` you will be able to use the classic C debugging techniques like Valgrind with Nim (otherwise Nim allocation pattern is opaque to Valgrind) * `--debugger:native` you will be able to use gdb/lldb with a reference to the Nim code you are currently stepping into, see also [https://nim-lang.org/blog/2017/10/02/documenting-profiling-and-debugging-nim-code.html](https://nim-lang.org/blog/2017/10/02/documenting-profiling-and-debugging-nim-code.html)
