Tricertops/KeepLayout

Expression is not an integer constant expression

Closed this issue · 2 comments

Xcode Version 6.1 (6A1052d)
in KeepTypes.h
row 24
typedef enum : NSInteger {
KeepPriorityRequired = UILayoutPriorityRequired,
KeepPriorityHigh = UILayoutPriorityDefaultHigh,
KeepPriorityLow = UILayoutPriorityDefaultLow,
KeepPriorityFitting = UILayoutPriorityFittingSizeLevel,
} KeepPriority;

has error : Expression is not an integer constant expression

and i think it could that do:
//typedef enum : NSInteger {
// KeepPriorityRequired = UILayoutPriorityRequired,
// KeepPriorityHigh = UILayoutPriorityDefaultHigh,
// KeepPriorityLow = UILayoutPriorityDefaultLow,
// KeepPriorityFitting = UILayoutPriorityFittingSizeLevel,
//} KeepPriority;

typedef float KeepPriority;
static const KeepPriority KeepPriorityRequired = UILayoutPriorityRequired;
static const KeepPriority KeepPriorityHigh = UILayoutPriorityDefaultHigh;
static const KeepPriority KeepPriorityLow = UILayoutPriorityDefaultLow;
static const KeepPriority KeepPriorityFitting = UILayoutPriorityFittingSizeLevel;

maybe it is right or may some other idea to fix!!

Please, update to the latest version. In case you are using CocoaPods, link directly to this repo.

ok,thx