启用所有异常断点后,始终在App委托中停止 [英] Always stop in App delegate after enabling All exceptions break point

查看:190
本文介绍了启用所有异常断点后,始终在App委托中停止的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我启用所有异常断点时,我的应用程序总是在AppDelegate中停止,但我能够继续执行程序,但它非常烦人的原因总是把我带到appdelegate。有什么想法吗?



解决方案

仅启用Objective-C断点。



要查看实际情况导致错误的语句添加异常断点:


  1. 从主菜单调试:断点:创建异常断点。


  2. 右键单击断点并将异常设置为Objective-C。这将忽略其他类型的异常,例如来自C ++。有部分API使用例如Core Data(Apple是 Special )等异常。


  3. 添加动作:po $ ARG1\" 。


运行应用程序以获取断点,您将位于导致异常的行,错误消息将在调试器控制台中。




When i enable all exceptions breakpoint my app always stops in AppDelegate, but im able to continue the program execution, but its very annoying cause always takes me to the appdelegate. Any ideas why?

解决方案

Only enable Objective-C breakpoints.

To see the actual statement that is causing the error add an exception breakpoint:

  1. From the Main Menu Debug:Breakpoints:Create Exception Breakpoint.

  2. Right-click the breakpoint and set the exception to Objective-C. This will ignore other types of exceptions such as from C++. There are parts of the APIs that use exceptions such as Core Data (Apple is Special).

  3. Add an action: "po $arg1".

Run the app to get the breakpoint and you will be at the line that causes the exception and the error message will be in the debugger console.

Breakpoint example:

这篇关于启用所有异常断点后,始终在App委托中停止的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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