xCode 6 how to fix “Use of undeclared identifier” for automatic property synthesis?

夙愿已清 提交于 2019-11-28 22:23:54

At first I thought it was a beta version bug, but today I saw that this type of errors occur on the XCode 6 GM Seed also, though I'm yet to discover in which particular cases.

Anyway, the fix is to add a synthesize statement in the @implementation block, explicitly declaring the name of the ivar as well as the property:

@synthesize property = _property

If you have an explicit getter, automatic property synthesized will be ignored.

Then you have to use @synthesize property = _property

pod update

then your can now update to 3.7.1 that has fixed this bug.

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