Available on crate feature
exception
only.Expand description
Throws an Objective-C exception.
This is the Objective-C equivalent of Rust’s panic!
.
Safety
This unwinds from Objective-C, and the exception must be caught using an
Objective-C exception handler like catch
(and specifically not
catch_unwind
).
This also invokes undefined behaviour until C-unwind
is stabilized, see
RFC-2945 - you can try this out on nightly using the unstable-c-unwind
feature flag.