问题
I was debugging my code and thought about a possibility of automatic stepping over or Step into line by line in the xCode debug mode. It would be more efficient to see the way the code will be executed line by line without clicking for every next step. Maybe theres a way you can set a timer for every next step. I was searching for something like that but there are too many posts for the debug mode which just explain the basic stuff.
回答1:
Maybe I'm not understanding the question, but the three key buttons are:
- "Step over", F6, continuing execution but stopping at the next line of code (but not single stepping through the method that the current line of code references); - "Step into", F7, continuing execution but stopping at the first line of code in the method your current line of code references; - "Step out", F8, continuing execution but stopping at code that called current method.See Control Program Execution of the Xcode Users Guide.
The other obvious technique is judicious use of setting breakpoints or setting "watch point" (i.e. have the debugger automatically pause whenever a particular variable changes).
Probably worth seeing Debugging in Xcode WWDC 2012 video
来源:https://stackoverflow.com/questions/16906592/automatic-step-over-in-xcode