Re: Break on assert

Carl Hoefs

Those appear to be Swift-specific. Nevertheless I tried breaking at assert, assertionFailure, precondition, preconditionFailure, fatalError, etc. No break.


On Oct 31, 2020, at 2:46 PM, Alex Zavatone via <zav@...> wrote:

Whatever should be explained in the links I sent you.

On Oct 31, 2020, at 4:42 PM, Carl Hoefs <newslists@...> wrote:

It's the 'whatever' that I'm having trouble with! I did try 'print' and NSLog, but it didn't break there either...


On Oct 31, 2020, at 2:39 PM, Steve Mills via <sjmills@...> wrote:

On Oct 31, 2020, at 16:18, Steve Mills <sjmills@...> wrote:

On Oct 31, 2020, at 16:15, Carl Hoefs <newslists@...> wrote:

I've tried all the incantations I can think of, including those you suggest along with -[NSException raise]. (This is an iOS app, if it matters any...)

How about NSLog, log, print, um, there are a bunch of lower level ones I can’t think of. slog? logv? Or whatever the newer system logging stuff is?

You can set a symbolic breakpoint on print or whatever, then turn on the Don’t Stop checkbox or whatever it’s called, then add an action to print the stack to the log. The last stack logged before the assert would be the one you want, right?

Steve via iPad

Join to automatically receive all group messages.