Having
enum {MyA, MyB, Null}; typedef NSNumber myEnum;
Or
typedef enum {MyA, MyB, Null} myEnum;
1) How do
Try to do it this way :
typedef enum { MyA, MyB, Null } myEnum;
Then, to create an array, wrap the numbers into NSNumbers objects :
NSNumber
NSArray *a = [NSArray arrayWithObjects:[NSNumber numberWithInteger:MyA], [NSNumber numberWithInteger:MyB], nil];