objective-c - 在 Xcode 变量 View 中更改变量描述

标签 objective-c swift xcode debugging

我想知道是否可以更改 Xcode 调试器中变量的描述,例如: Xcode Debugger

我想根据对象本身更改红色框中的文本。 NSArray 具有@“10 个元素”的描述。

最佳答案

来自 Xcode 帮助:

To edit the summary format of a variable, Control-click the variable and choose Edit Summary Format… from the shortcut menu.

In the popover, enter a valid LLDB expression and click Done. This expression overrides the default formatter and is used to create a summary for all variables of this type.

关于objective-c - 在 Xcode 变量 View 中更改变量描述,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45767475/

相关文章:

ios - pickerview 随机崩溃 didSelect : __cfrunloop_is_calling_out_to_a_source1_perform1_function

ios - 您需要 iOS 上的数据保护功能吗?

iphone - 即使应用程序在后台运行且未打开,WhatsApp 如何知道用户是否收到推送通知?

ios - 防止进入静态库代码

iphone - 如何取消之前在 Objective-C 中安排的事件?

objective-c - 需要建议在 iOS 中处理大型矢量图形

ios - 从可重用的 UITableViewCell 对象开始视频播放

ios - GMSMapView 在 iOS 中放大或缩小时显示 GMSMarker 计数

ios - 将 tableView 装入其父 UIViewController

Objective-C:如何在 switch 语句完成后返回到应用程序的开头