I am receiving the error function definition is not allowed here
on all three enum
s. I recently updated to Xcode 6.0.1 and I am receiving that error now. How can I fix this error, should I avoid using this macro. I have also set the target SDK to ios 6.0 which supports these macros.
BConstants.h
#ifndef asdf_BPConstants_h
#define asdf_BPConstants_h
typedef NS_ENUM(NSUInteger, BTheme) {
kField
};
typedef NS_ENUM(NSUInteger, BItem) {
kBox
};
typedef NS_ENUM(NSUInteger, BMovementState) {
kTouchUp,
kTouchDown
};
#endif
Importing UIKit fixed this for me.
#import <UIKit/UIKit.h>
Importing Foundation
should be enough.
@import Foundation;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With