Xcode没有在断点处停止 [英] Xcode not stopping on breakpoint

查看:65
本文介绍了Xcode没有在断点处停止的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

自从我将Xcode从4.6升级到5以来,我对Xcode遇到了一些奇怪的问题.当我在文件中设置断点时,该程序实际上在断点处停止,但是在工作区中看不到我的代码.它会加载其他一些系统代码,例如

I have some weird problem with Xcode since I upgraded my Xcode to 5 from 4.6. When I set the breakpoint in a file, the program actually stops at the breakpoint, but I can't see my code in the workspace. It loads some other system codes like

 0x2ff8:  calll  0x2ffd  -[ViewController viewDidLoad] + 13 at ViewController.m:28
0x2ffd:  popl   %eax
0x2ffe:  movl   12(%ebp), %ecx
0x3001:  movl   8(%ebp), %edx
0x3004:  movl   %edx, -12(%ebp)
0x3007:  movl   %ecx, -16(%ebp)
0x300a:  movl   18799(%eax), %ecx
0x3010:  movl   18559(%eax), %edx

当我单击继续按钮时,它将再次显示我的代码.我已经尝试过了,

When I click the continue button it shows my code again. I have tried,

  • 创建一个新项目
  • 重新启动Xcode
  • 重启系统
  • 重新安装Xcode

这些都没有帮助我.我在StackOverflow中看到了很多讨论断点不起作用..."的问题,但是对我来说,断点正在起作用,只是没有停在正确的位置.

None of these helped me. I have seen a lot of questions in StackOverflow which discuss "Breakpoints not working...", but for me the breakpoints are working, just not stopping in the correct position.

推荐答案

我发现了问题所在,即调试时显示反汇编".在我的Xcode中启用,从而造成了该问题.当我禁用它时,我的所有调试器都停止在我的源代码中.

I found the problem, Somehow the "Show Disassembly when debugging" was enabled in my Xcode which creates that problem. When I disabled it, all my debugger stopped in my source code.

您可以在产品->调试工作流程->调试时显示反汇编下找到它

You can find it under Product->Debug Workflow->Show Disassembly when debugging

修改

在最新的Xcode中,它位于 Debug-> Debug Workflow->调试时显示反汇编

In the latest Xcode it is under Debug->Debug Workflow->Show Disassembly when debugging

这篇关于Xcode没有在断点处停止的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆