开发者

UIImageView error with OCUnit

am using OCUnit to test my application however am running into some trouble. When I attempt to include a class that contains an instance variable of type UIImageView, I get the following error: "Expected specifier-qualifier-list before UIImageView"

My declaration code is:

UIImageView *_icon;

I can't work out whats causing this and it only happens when I attempt to build my application using my test target.

Tha开发者_如何学编程nks


Your test target doesn't know what UIImageView is. It needs its own precompiled-header referencing UIKit (or you could import UIKit in that file), and it needs to link that framework.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜