On Jul 1, 2015, at 17:50 , Rick Mann <rm...@latencyzero.com> wrote: > > I didn't think it was possible to not return. Maybe an assert() is better in > this situation, because I think it always indicates a programming mistake.
Indeed it is possible. There are three possible functions: fatalError (“message”) preconditionFailure (“message”) precondition (booleanCondition, “message”) I’m not sure what the difference is between the first two, but I’ve noticed that ‘fatalError’ crashes with an illegal instruction — deliberately, I assume. ‘assert’ isn’t a good choice, because it doesn’t do anything in a Release configuration build. That’s where it’s actually more important for it to crash. _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com