AQXMLParser错误:当前的部署目标不支持自动化__weak refrences
问题描述:
我想将AQXMLParser添加到我的应用程序,以及我尝试设置它的其他问题中有几个与我的问题标题相关的错误。AQXMLParser错误:当前的部署目标不支持自动化__weak refrences
The current deployment target does not support automated __weak refrences
我在想,以前有人遇到过这个问题。
这是他们对在AQXMLParser.h文件什么线路:
id __weak _delegate;
id<AQXMLParserProgressDelegate> __weak _progressDelegate;
@property (nonatomic, assign) id __weak delegate;
@property (nonatomic, assign) id<AQXMLParserProgressDelegate> __weak progressDelegate;
答
__weak不会在iOS 4.x版和更早。看起来AQXMLParser是为GC设计的(在Mac上),或者更可能的是,ARC(在iOS5 +上)。
好吧,我读了这个其他地方,但是我还以为我正在使用基于ios5的代码..但是现在我想我错了..时间来检查。 –
hm。考虑一下,在ARC中这样做的方式是@property(非原子,弱)。这看起来更像GC代码。 –
我的代码曾经是4.2我已经将我的depoyment目标更改为5.0,并且我的基本sdk更改为5.0 ...但仍然存在错误我还需要更改其他什么来更改我的代码5.0 –