Expected specifier-qualifier-list before 'CGPoint'

Posted by Rob on Stack Overflow See other posts from Stack Overflow or by Rob
Published on 2010-05-20T14:26:27Z Indexed on 2010/05/20 14:50 UTC
Read the original article Hit count: 231

My project compiles and runs fine unless I try to compile my Unit Test Bundle it bombs out on the following with an "Expected specifier-qualifier-list before 'CGPoint'" error on line 5:

#import <Foundation/Foundation.h>
#import "Force.h"

@interface WorldObject : NSObject {
    CGPoint coordinates;
    float altitude;
    NSMutableDictionary *forces;
}

@property (nonatomic) CGPoint coordinates;
@property (nonatomic) float altitude;
@property (nonatomic,retain) NSMutableDictionary *forces;

- (void)setObject:(id)anObject inForcesForKey:(id)aKey;
- (void)removeObjectFromForcesForKey:(id)aKey;
- (id)objectFromForcesForKey:(id)aKey;
- (void)applyForces;

@end

I have made sure that my Unit Test Bundle is a target of my WorldObject.m and it's header is imported in my testing header:

#define USE_APPLICATION_UNIT_TEST 1

#import <SenTestingKit/SenTestingKit.h>
#import <UIKit/UIKit.h>
#import "Force.h"
#import "WorldObject.h"


@interface LogicTests : SenTestCase {
    Force *myForce;
    WorldObject *myWorldObject;
}

@end

© Stack Overflow or respective owner

Related posts about objective-c

Related posts about iphone-sdk-3.0