enum { /* Constants returned by -operatingSystem */
NSWindowsNTOperatingSystem = 1,
NSWindows95OperatingSystem,
NSSolarisOperatingSystem,
NSHPUXOperatingSystem,
NSMACHOperatingSystem,
NSSunOSOperatingSystem,
NSOSF1OperatingSystem
};
But when you see the definition of the operatingSystem function, it actually returns integer (rather than the enum)!
- (NSUInteger)operatingSystem;
You could:
typedef enum { ... } OS;
- (OS)operatingSystem;
but as it all evaluates to int in the end no types will be checked and so it will be no help to you anyway!