判断是否为null
//尖括号
if ([regeocode.city isEqual:[NSNull class]]) {
NSLog(@"123");
}
//圆括号
if (regeocode.city == nil) {
NSLog(@"345");
}
转载于:https://www.cnblogs.com/sayimba/p/5660144.html