1*f4a2713aSLionel Sambuc// RUN: %clang_cc1 -Wduplicate-method-match -fsyntax-only -verify -Wno-objc-root-class %s 2*f4a2713aSLionel Sambuc 3*f4a2713aSLionel Sambuc@interface Subclass 4*f4a2713aSLionel Sambuc{ 5*f4a2713aSLionel Sambuc int ivar; 6*f4a2713aSLionel Sambuc} 7*f4a2713aSLionel Sambuc 8*f4a2713aSLionel Sambuc- (void) method; // expected-note {{previous declaration is here}} 9*f4a2713aSLionel Sambuc- (void) method; // expected-warning {{multiple declarations of method 'method' found and ignored}} 10*f4a2713aSLionel Sambuc@end 11*f4a2713aSLionel Sambuc 12*f4a2713aSLionel Sambuc@implementation Subclass 13*f4a2713aSLionel Sambuc- (void) method {;} // expected-note {{previous declaration is here}} 14*f4a2713aSLionel Sambuc- (void) method {;} // expected-error {{duplicate declaration of method 'method'}} 15*f4a2713aSLionel Sambuc@end 16*f4a2713aSLionel Sambuc 17*f4a2713aSLionel Sambucint main (void) { 18*f4a2713aSLionel Sambuc return 0; 19*f4a2713aSLionel Sambuc} 20