diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2014-03-17 17:46:10 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2014-03-17 17:46:10 +0000 |
commit | 83d674e007d07fba56bbdbd92475ed25ef33ded9 (patch) | |
tree | c986e4fb97b73bfd821cfc88b0e8af4db27a4d52 /clang/test | |
parent | 263c9280b343b27e258cf0dc34cc1fe10ba2b924 (diff) | |
download | bcm5719-llvm-83d674e007d07fba56bbdbd92475ed25ef33ded9.tar.gz bcm5719-llvm-83d674e007d07fba56bbdbd92475ed25ef33ded9.zip |
Objective-C. Do not warn when an instance method and
class method with the same selctor but different argument
types having one of them in class extension.
// rdar://16312105
llvm-svn: 204065
Diffstat (limited to 'clang/test')
-rw-r--r-- | clang/test/SemaObjC/class-extension-dup-methods.m | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/clang/test/SemaObjC/class-extension-dup-methods.m b/clang/test/SemaObjC/class-extension-dup-methods.m index 692ff8c68a0..5f463aed168 100644 --- a/clang/test/SemaObjC/class-extension-dup-methods.m +++ b/clang/test/SemaObjC/class-extension-dup-methods.m @@ -13,3 +13,16 @@ + (int) InstMeth; - (int) OK; @end + +// rdar://16312105 +@class NSObject; + +__attribute__((objc_root_class)) @interface AppDelegate ++ (void)someMethodWithArgument:(NSObject *)argument; ++ (void)someMethodWithArgument:(NSObject *)argument : (NSObject*) argument2; // expected-note {{previous declaration is here}} +@end + +@interface AppDelegate () +- (void)someMethodWithArgument:(float)argument; // OK. No warning to be issued here. ++ (void)someMethodWithArgument:(float)argument : (float)argument2; // expected-error {{duplicate declaration of method 'someMethodWithArgument::'}} +@end |