Why does NSObject's “isMemberOfClass:class” specify __unsafe_unretained in XCode's autocompletion?

丶灬走出姿态 提交于 2019-11-30 22:38:54

In the absence of an explicit ownership qualification one is inferred; this is usually __strong but in the case of Class it is __unsafe_unretained. This makes sense as Class objects are immortal and need not be memory managed by your code.

So Xcode is just making the implicit explicit and you do not need to do this yourself.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!