A reimplementation of NSException. This repository has no use for anyone that isn't attempting to reimplement Foundation from scratch. MXException is, to the best of my knowledge, perfectly behaviourally compatible at a public API level, provided one replaces all occurences of "MX" with "NS". Binary compatibility is hypothetically achievable by renaming the ivars (_callStackData should be renamed to reserved, all other ivars have no leading underscore) and implementing a few private methods (-redactedDescription, -_installStackTraceKeyIfNeeded, -_markAsArchived, and -_isArchived).
All test cases were written by "le clanker". MXException.{h,m} and main.m are entirely brain-generated. MXException is compiled with -std=c23, but replacing the singular occurrence of nullptr with NULL eliminates any requirement for C23 language features.
Open in Xcode and smack Command-B.
Select a desired testing schema with "Product->Scheme", then smack Command-U to run. All tests should pass under all schemas covering all sanitizers. If they don't, whoops, I messed something up.