gpt4 book ai didi

iphone - Xcode 调试器 : view value of variable

转载 作者:IT老高 更新时间:2023-10-28 11:19:43 27 4
gpt4 key购买 nike

我在 UITableViewController 中的代码:

delegate.myData = [myData objectAtIndex:indexPath.row];

如何在调试器中查看 delegate.myDataindexPath.row 的值? delegate.myData 应该是一个数组,而 indexPath.row 应该是一个 int。我只能看到对象 delegateindexPath 的内存地址,但是 myDatarow 在哪里?

alt text

最佳答案

查看 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/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com