Is it possible to catch a NSInternalInconsistencyException in Swift?

i0S Swift Issue

Question or problem in the Swift programming language:

Is it possible to catch a NSInternalInconsistencyException in Swift ?
If it is, how could that be done?

How to solve the problem:

It can be done for example with https://github.com/williamFalcon/SwiftTryCatch. First add it to your Podfile:

use_frameworks!
pod 'SwiftTryCatch'

Then in your code import SwiftTryCatch and then you can catch Objective-C exceptions like this

SwiftTryCatch.try({ 
    // try block
}, catch: { (error) in
    // catch block
}, finally: {
    // finally block
})

Hope this helps!