1f4a2713aSLionel Sambuc// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s 2f4a2713aSLionel Sambuc 3*0a6a1f1dSLionel Sambuc@interface MyClass 4f4a2713aSLionel Sambuc@end 5f4a2713aSLionel Sambuc 6f4a2713aSLionel Sambuc@protocol P 7f4a2713aSLionel Sambuc- (void)Pmeth; 8f4a2713aSLionel Sambuc- (void)Pmeth1; // expected-note {{method 'Pmeth1' declared here}} 9f4a2713aSLionel Sambuc@end 10f4a2713aSLionel Sambuc 11f4a2713aSLionel Sambuc// Class extension 12f4a2713aSLionel Sambuc@interface MyClass () <P> 13f4a2713aSLionel Sambuc- (void)meth2; // expected-note {{method 'meth2' declared here}} 14f4a2713aSLionel Sambuc@end 15f4a2713aSLionel Sambuc 16f4a2713aSLionel Sambuc// Add a category to test that clang does not emit warning for this method. 17f4a2713aSLionel Sambuc@interface MyClass (Category) 18f4a2713aSLionel Sambuc- (void)categoryMethod; 19f4a2713aSLionel Sambuc@end 20f4a2713aSLionel Sambuc 21*0a6a1f1dSLionel Sambuc@implementation MyClass // expected-warning {{method 'Pmeth1' in protocol 'P' not implemented}} \ 22f4a2713aSLionel Sambuc // expected-warning {{method definition for 'meth2' not found}} 23f4a2713aSLionel Sambuc- (void)Pmeth {} 24f4a2713aSLionel Sambuc@end 25