ios - Multiple methods named 'integerValue' found with mismatched
迷茫
迷茫 2017-04-17 13:53:57
0
1
545

我加入了下面这个类:

    #import "NSNull+NullCast.h"

@implementation NSNull (NullCast)

- (float)floatValue
{

    return 0.0;

}

- (double)doubleValue
{
    return 0.0;
}

- (int)intValue
{

    return 0;

}  

- (int)integerValue
{
    return 0;
}

在iPhone5s-ios8.1报错如下:

Multiple methods named 'integerValue' found with mismatched result, parameter type or attributes

可是奇怪的是iPhone5-ios8.1却顺利编译通过。

一样的操作系统,难道机型不一样也不行?看报错是ARC报错

迷茫
迷茫

业精于勤,荒于嬉;行成于思,毁于随。

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!