判断是否为null//尖括号 if ([regeocode.city isEqual:[NSNull class]]) { NSLog(@"123"); } //圆括号 if (regeocode.city == nil) { NSLog(@"345"); }