Re: How to debug a segmentation fault?

2019-12-09 Thread AmbrusFernas
I'm working on a Reverse Polish Notation calculator for my Data Structures class and I get a segfault when I pass arguments to the program at runtime. How do you guys troubleshoot errors without line numbers?

Re: How to debug a segmentation fault?

2019-11-30 Thread doofenstein
do you iterate over the array? Then it might be related to [https://github.com/nim-lang/Nim/issues/12747](https://github.com/nim-lang/Nim/issues/12747)

Re: How to debug a segmentation fault?

2019-11-30 Thread spip
Thanks, it was effectively a stack overflow. Having a ref array instead of an array defined for the matrix type used as deeper procs' parameters did the trick.

Re: How to debug a segmentation fault?

2019-11-30 Thread Araq
> Is there something I can try before creating a minimal example and opening a > bug? Reduce the involved data structure sizes and see if the crash disappears. If so, you might simply put too much data onto the stack causing a crash.

How to debug a segmentation fault?

2019-11-30 Thread spip
My program does not do tricky system things, only using ref object to build a toroid matrix, letting the compiler initialize all the objects. It segfaults when building the matrix, without any stack trace. I've tried placing echo and debugEcho in calls to get how far in the code it runs, but apa