除了 NSZombieEnabled 之外还有哪些其他调试参数?
我在发布或未保留某些内容时遇到问题,Xcode 不会准确显示错误所在。
我正在与一个人合作,他有一个组织得非常糟糕的项目,我认为 Xcode 甚至吓坏了,因为抛出了 [CALAyer release]
,但没有解释什么或在哪里。
I am having issues with something being released or not retained, and Xcode will not show me exactly where the error is at.
I am working collaboratively with an individual who has a horribly organized project, and I think Xcode is even freaking out, because [CALAyer release]
is thrown, but no explanation of what or where.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
对于环境变量,您可以读取
NSDebug.h
(在终端中使用open -h NSDebug.h
)。尽管 NSZombieEnabled 是其中最有用的一个。如果您需要调试对象生命周期问题,请将 Instruments 与 Zombies 仪器结合使用。然后,您可以查看任何给定对象发生的所有保留/释放/自动释放事件。For env variables, you can read
NSDebug.h
(useopen -h NSDebug.h
in the Terminal). Though NSZombieEnabled is the most useful one there. If you need to debug object lifetime issues, use Instruments with the Zombies instrument. You can then see all the retain/release/autorelease events that happened for any given object.