Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>When we start debug from xcode, the debugger sets itself up to monitor signals from OS. When we press stop button in XCode (or hit cmd + R - which first stops existing instance running and then try to start new one, somewhat equalant to we press manually stop first and then run) <strong>SIGKILL is sent to the debugger</strong>. </p> <p>Whenever the cause of interruption is from outside the app (in other words all cases where SIGKILL is sent, like stop button press) , debugger jumps to <code>main</code>, since <strong>main is the root of the app and the place where your app meets the OS</strong>. Debugger has no way to identify why this SIGKILL is issued (pressing stop button in xcode/ press cmd + R/ delete app from multitasking bar etc), but <strong>it treats SIGKILL as outside interrupt, and nothing related with your code</strong>. So it jumps to main. </p> <p>If the cause of interruption is from inside the app (like app crash/SIGABRT) debugger handles it and jumps to the place of crash, which we normally see.</p> <p>I do not consider this as an xcode bug, rather a normal way of handling SIGKILL. But if you want to stay at your code and do not want to jump to main you can do two things</p> <ol> <li><p>You can do as Gabe suggested. As BBonified said, it is like a band-aide, but I think it should work (personally I never tried that)</p></li> <li><p>Report a bug/request for a feature <a href="http://developer.apple.com/bugreporter/" rel="nofollow">here</a>. Let me tell you you are not the first one to do so. Already a bug has been reported. See <a href="https://devforums.apple.com/message/555098#555098" rel="nofollow">this</a> and <a href="https://devforums.apple.com/message/492920#492920" rel="nofollow">this</a>. But I don't have much hope of a positive action from Apple</p></li> </ol> <p>And I agree with you, it is sometimes annoying. Especially if you have experienced differently in previous XCode versions. But we can only take what they give here.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload