#define A7VERSION() ({[[[[[UIDevice currentDevice] systemVersion] componentsSeparatedByString:@"."] objectAtIndex:0] intValue];})
#define IS_OS_7 A7VERSION()>=7
The above declaration seems to compile well.
But as soon as I add it a .m file I get the following exception "invalid token at start of a preprocessor expression". I am not able to understand where I could be wrong
@implementation AppViewController
#if IS_OS_7
….
#else
….
#endif
@end