So my question: array index out of bound may not throw exception
in D?
I tried DMD and LDC, both have this problem.
Is there any flag I can pass to the compiler to let it always
throw exception?
Thanks.
ich is much
> harder to debug (than exception which tells the exact error and
> source line location).
>
> So my question: array index out of bound may not throw exception
> in D?
>
> I tried DMD and LDC, both have this problem.
>
> Is there any flag I can pass to the compi
On Friday, 21 July 2023 at 21:27:45 UTC, mw wrote:
However, I just debugged a case, where out of bound array index
didn't throw exception, and just hang the thread
Uncaught exceptions in a thread terminate that thread and are
reported when you call the `join` method of the thread.
I think yo
On Friday, 21 July 2023 at 23:32:41 UTC, Adam D Ruppe wrote:
On Friday, 21 July 2023 at 21:27:45 UTC, mw wrote:
However, I just debugged a case, where out of bound array
index didn't throw exception, and just hang the thread
Uncaught exceptions in a thread terminate that thread and are
report
On Friday, 21 July 2023 at 23:40:44 UTC, mw wrote:
Is there a way to let it report on the spot when it happens?
The best way is to wrap your thread's main function in a
try-catch block and just print whatever error/exception is caught.
On Friday, 21 July 2023 at 23:40:44 UTC, mw wrote:
Is there a way to let it report on the spot when it happens?
On linux if you catch an exception and call abort, the debugger
will show you where abort was called, on windows you can call
DebugBreak function, the debugger will show where it wa