On Thursday, 6 July 2023 at 06:17:34 UTC, Richard (Rikki) Andrew
Cattermole wrote:
2 Recommendations:
1. Attach a debugger
2. Make sure to flush stdout whenever you write
I assumed that buffering was to blame. How do I flush stdout?
I moved to an x86-64 box. I was using my ARM M2 Mac for which I
have no debugger. There must be one somewhere though. I got a
visible crash on the x86 machine, array index off the end by one,
so I attached gdb and saw the bug. Yay!
I’m not sure why there was no crash error message on the ARM Mac
though. I had the array length wildly wrong. I then fixed the
offending code that was doing the accounting wrongly.