Conflicting return type in implementation of 'supportedInterfaceOrientations': - Warning
Solution 1:
Try this tweak:
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 90000
- (NSUInteger)supportedInterfaceOrientations
#else
- (UIInterfaceOrientationMask)supportedInterfaceOrientations
#endif
{
return UIInterfaceOrientationMaskPortrait;
}
Solution 2:
I am using this one:
#if __IPHONE_OS_VERSION_MAX_ALLOWED < __IPHONE_9_0
#define supportedInterfaceOrientationsReturnType NSUInteger
#else
#define supportedInterfaceOrientationsReturnType UIInterfaceOrientationMask
#endif
- (supportedInterfaceOrientationsReturnType)supportedInterfaceOrientations {
return UIInterfaceOrientationMaskPortrait;
}
... a little bit longer than Nishant's fix but a little bit clearer, I think.