我在-prefix.pch文件中添加了一些东西,但是XCode在我使用它时给了我错误,说
使用未定义的标识符......
但是如果我编译它(Command + B),它编译,所以我认为它是由派生数据引起的,然后我试图删除派生数据(从而迫使它再次重新生成)但是在Organizer那里该项目没有派生数据,我也尝试过Clean但不起作用。
有人可以帮忙吗?
编辑:我定义的宏对于这个问题并不重要,但这里是宏:
#define IPAD (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad)
编辑2:我将Kiwi作为单元测试工具添加到项目中,可能是项目设置中的某些内容发生了变化而导致了问题。
答案 0 :(得分:0)
You will need to include inly framework related headers and also adding header in pch file means you need not import that header in any of the file in your project.
#import <Availability.h>
#ifndef __IPHONE_3_0
#warning "This project uses features only available in iOS SDK 3.0 and later."
#endif
#ifdef __OBJC__
#import <UIKit/UIKit.h>
#import <Foundation/Foundation.h>
#endif
答案 1 :(得分:0)