williamFalcon / SwiftTryCatch

Adds try-catch support for Swift
MIT License
140 stars 58 forks source link

Does not catch all exceptions, even very similar ones. #10

Closed davidbjames closed 6 years ago

davidbjames commented 8 years ago

I'm using SwiftTryCatch with an Objective-C library which throws validation exceptions if the provided data is invalid. In all cases the exceptions look like this:

@throw [NSException exceptionWithName:NSInvalidArgumentException reason:[NSString stringWithFormat:@".. message .."] userInfo:nil];

For certain exceptions, SwiftTryCatch always catches, and for others, never. Why might this be?