@implementation Derived
+ (int) class_func1
{
- int i = (int)[self class_func0]; /* { dg-warning ".Derived. may not respond to .\\+class_func0." } */
+ int i = (size_t)[self class_func0]; /* { dg-warning ".Derived. may not respond to .\\+class_func0." } */
/* { dg-warning "Messages without a matching method signature" "" { target *-*-* } 47 } */
/* { dg-warning "will be assumed to return .id. and accept" "" { target *-*-* } 47 } */
/* { dg-warning ".\.\.\.. as arguments" "" { target *-*-* } 47 } */
- return i + (int)[super class_func0]; /* { dg-warning ".Object. may not respond to .\\+class_func0." } */
+ return i + (size_t)[super class_func0]; /* { dg-warning ".Object. may not respond to .\\+class_func0." } */
}
+ (int) class_func2
{
}
+ (int) class_func5
{
- int i = (int)[Derived class_func0]; /* { dg-warning ".Derived. may not respond to .\\+class_func0." } */
- return i + (int)[Object class_func0]; /* { dg-warning ".Object. may not respond to .\\+class_func0." } */
+ int i = (size_t)[Derived class_func0]; /* { dg-warning ".Derived. may not respond to .\\+class_func0." } */
+ return i + (size_t)[Object class_func0]; /* { dg-warning ".Object. may not respond to .\\+class_func0." } */
}
+ (int) class_func6
{
- return (int)[OBJC_GETCLASS("Object") class_func1]; /* { dg-warning ".Object. may not respond to .\\+class_func1." } */
+ return (size_t)[OBJC_GETCLASS("Object") class_func1]; /* { dg-warning ".Object. may not respond to .\\+class_func1." } */
}
+ (int) class_func7
{
}
- (int) instance_func1
{
- int i = (int)[self instance_func0]; /* { dg-warning ".Derived. may not respond to .\\-instance_func0." } */
- return i + (int)[super instance_func0]; /* { dg-warning ".Object. may not respond to .\\-instance_func0." } */
+ int i = (size_t)[self instance_func0]; /* { dg-warning ".Derived. may not respond to .\\-instance_func0." } */
+ return i + (size_t)[super instance_func0]; /* { dg-warning ".Object. may not respond to .\\-instance_func0." } */
}
- (int) instance_func2
{
}
- (int) instance_func5
{
- int i = (int)[Derived instance_func1]; /* { dg-warning ".Derived. may not respond to .\\+instance_func1." } */
- return i + (int)[Object instance_func1]; /* { dg-warning ".Object. may not respond to .\\+instance_func1." } */
+ int i = (size_t)[Derived instance_func1]; /* { dg-warning ".Derived. may not respond to .\\+instance_func1." } */
+ return i + (size_t)[Object instance_func1]; /* { dg-warning ".Object. may not respond to .\\+instance_func1." } */
}
- (int) instance_func6
{
- return (int)[OBJC_GETCLASS("Object") class_func1]; /* { dg-warning ".Object. may not respond to .\\+class_func1." } */
+ return (size_t)[OBJC_GETCLASS("Object") class_func1]; /* { dg-warning ".Object. may not respond to .\\+class_func1." } */
}
- (int) instance_func7
{
@implementation Derived (Categ)
+ (int) categ_class_func1
{
- int i = (int)[self class_func0]; /* { dg-warning ".Derived. may not respond to .\\+class_func0." } */
+ int i = (size_t)[self class_func0]; /* { dg-warning ".Derived. may not respond to .\\+class_func0." } */
i += [self class_func1];
i += [self categ_class_func2];
- i += (int)[self categ_instance_func1]; /* { dg-warning ".Derived. may not respond to .\\+categ_instance_func1." } */
- return i + (int)[super class_func0]; /* { dg-warning ".Object. may not respond to .\\+class_func0." } */
+ i += (size_t)[self categ_instance_func1]; /* { dg-warning ".Derived. may not respond to .\\+categ_instance_func1." } */
+ return i + (size_t)[super class_func0]; /* { dg-warning ".Object. may not respond to .\\+class_func0." } */
}
+ (int) categ_class_func2
{
}
- (int) categ_instance_func1
{
- int i = (int)[self instance_func0]; /* { dg-warning ".Derived. may not respond to .\\-instance_func0." } */
+ int i = (size_t)[self instance_func0]; /* { dg-warning ".Derived. may not respond to .\\-instance_func0." } */
i += [(Derived <Func> *)self categ_instance_func2];
- i += (int)[(Object <Func> *)self categ_instance_func2]; /* { dg-warning ".Object. may not respond to .\\-categ_instance_func2." } */
+ i += (size_t)[(Object <Func> *)self categ_instance_func2]; /* { dg-warning ".Object. may not respond to .\\-categ_instance_func2." } */
/* { dg-warning ".\\-categ_instance_func2. not implemented by protocol" "" { target *-*-* } 129 } */
- i += (int)[(id <Func>)self categ_instance_func2]; /* { dg-warning ".\\-categ_instance_func2. not implemented by protocol" } */
+ i += (size_t)[(id <Func>)self categ_instance_func2]; /* { dg-warning ".\\-categ_instance_func2. not implemented by protocol" } */
i += [(id)self categ_instance_func2];
- return i + (int)[super instance_func0]; /* { dg-warning ".Object. may not respond to .\\-instance_func0." } */
+ return i + (size_t)[super instance_func0]; /* { dg-warning ".Object. may not respond to .\\-instance_func0." } */
}
- (int) categ_instance_func2
{