Dasem Dasem - 1 month ago 6
iOS Question

xcode show the implementation of custom framework when there is an error

is xcode suppose to show the implementation of custom framework when there is an error?

i have made a custom framework, and it's works fine,
it's look like this:
enter image description here

in my viewcontroller i have a button action, that call a method in the framework

@IBAction func buttonPressed(sender: UIButton) {
dview.exchangeSubviewAtIndex(0, withSubviewAtIndex: 2, animated: true)
}


since i have only 3 subviews the button action will work,
however, if i do this:

@IBAction func buttonPressed(sender: UIButton) {
dview.exchangeSubviewAtIndex(0, withSubviewAtIndex: 20, animated: true)
}


it's will crash, and it's ok, since i pass a value that does'nt exist in the array, but i didn't expected xcode to show the implementation of the framework,
instead xcode takes me to the line of code in the implementation :

enter image description here

basically, i don't want it to show the implementation of code in the framework..

Answer

Your framework contains debug information which includes file locations.

Since you are using the same machine, lldb debugger is able to locate the source code where your app crashed.

You can move the Framework's Xcode project to different location on your Mac to see the difference.