我在 UITableViewController 中的代码:
delegate.myData = [myData objectAtIndex:indexPath.row];
如何在调试器中查看 delegate.myData
或 indexPath.row
的值? delegate.myData
应该是一个数组,而 indexPath.row
应该是一个 int
。我只能看到对象 delegate
和 indexPath
的内存地址,但是 myData
和 row
在哪里?
最佳答案
查看 How to view contents of NSDictionary variable in Xcode debugger?
我也用过
po variableName
print variableName
在控制台中。
在你的情况下可以执行
print [myData objectAtIndex:indexPath.row]
或
po [myData objectAtIndex:indexPath.row]
关于iphone - Xcode 调试器 : view value of variable,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4735156/