2009-12-16 04:14:24 +08:00
|
|
|
// RUN: %clang_cc1 -fsyntax-only -verify %s
|
2007-10-04 08:22:33 +08:00
|
|
|
|
2010-03-28 05:10:05 +08:00
|
|
|
@interface MyClass1
|
2007-10-03 00:38:50 +08:00
|
|
|
@end
|
|
|
|
|
|
|
|
@protocol P
|
2010-10-30 07:20:05 +08:00
|
|
|
- (void) Pmeth; // expected-note {{method declared here }}
|
|
|
|
- (void) Pmeth1; // expected-note {{method declared here }}
|
2007-10-03 00:38:50 +08:00
|
|
|
@end
|
|
|
|
|
2010-03-28 05:10:05 +08:00
|
|
|
@interface MyClass1(CAT) <P> // expected-note {{required for direct or indirect protocol 'P'}}
|
2010-03-28 03:02:17 +08:00
|
|
|
- (void) meth2; // expected-note {{method definition for 'meth2' not found}}
|
2007-10-03 00:38:50 +08:00
|
|
|
@end
|
|
|
|
|
2010-10-30 07:20:05 +08:00
|
|
|
@implementation MyClass1(CAT) // expected-warning {{incomplete implementation}} \
|
|
|
|
// expected-warning {{method in protocol not implemented [-Wprotocol]}}
|
2007-10-03 00:38:50 +08:00
|
|
|
- (void) Pmeth1{}
|
2007-10-04 08:22:33 +08:00
|
|
|
@end
|
2007-10-03 00:38:50 +08:00
|
|
|
|
2010-03-28 05:10:05 +08:00
|
|
|
@interface MyClass1(DOG) <P> // expected-note {{required for direct or indirect protocol 'P'}}
|
2010-10-30 07:20:05 +08:00
|
|
|
- (void)ppp; // expected-note {{method definition for 'ppp' not found}}
|
2007-10-03 00:38:50 +08:00
|
|
|
@end
|
|
|
|
|
2010-10-30 07:20:05 +08:00
|
|
|
@implementation MyClass1(DOG) // expected-warning {{incomplete implementation}} \
|
|
|
|
// expected-warning {{method in protocol not implemented [-Wprotocol]}}
|
2007-10-03 00:38:50 +08:00
|
|
|
- (void) Pmeth {}
|
2007-10-04 08:22:33 +08:00
|
|
|
@end
|
2007-10-03 00:38:50 +08:00
|
|
|
|
|
|
|
@implementation MyClass1(CAT1)
|
|
|
|
@end
|