0

I heard MATLAB supports post-mortem debugging (enter debugger upon encountering error), how to enable it?

3
  • I first learned it somewhere, then forgot, then not a single search result for "matlab post mortem debugging", then only found it from digging in my notes, so here be it. Commented Oct 25, 2023 at 15:29
  • I think that's perhaps because dbstop if error or similar isn't quite the same as what is probably usually meant by "post-mortem debugging" - you get to debug a still-live MATLAB process. Commented Oct 26, 2023 at 8:40
  • Yeah just superficial guessing. It's a super useful feature, think it should be mentioned in dbstop or even here. (Also I think you meant to comment on the answer) Commented Oct 26, 2023 at 9:58

1 Answer 1

1

Using dbstop:

dbstop if caught error

disable with dbclear:

dbclear all

There's likely a way to disable only it, rather than clearing all db stuff, but I'm unaware of what it is (it's not dbclear if caught error or dbclear if error).

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.