32@implementation NSNumber (OOExtensions)
36#if __COREFOUNDATION_CFNUMBER__
37 return CFNumberIsFloatType((CFNumberRef)
self);
43 const char *type = [
self objCType];
44 return (strcmp(type, @encode(
double)) == 0 || strcmp(type, @encode(
float)) == 0);
60#if __COREFOUNDATION_CFNUMBER__
61 return self == (NSNumber *)kCFBooleanTrue ||
self == (NSNumber *)kCFBooleanFalse;
63 static NSNumber *sTrue =
nil, *sFalse;
66 sTrue = [[NSNumber numberWithBool:YES] retain];
67 sFalse = [[NSNumber numberWithBool:NO] retain];
69 return self == sTrue ||
self == sFalse;