diff options
author | Steve Naroff <snaroff@apple.com> | 2008-10-21 10:37:50 +0000 |
---|---|---|
committer | Steve Naroff <snaroff@apple.com> | 2008-10-21 10:37:50 +0000 |
commit | a0ed165a847103a949ff2dffae38779736a32f54 (patch) | |
tree | 3a8c7bfdfa47687c7e7c9e81844d84b9f94eecc4 /clang/test/SemaObjC/method-lookup-3.m | |
parent | dab76fd8227dae3aa8db070b3cfd212361757c64 (diff) | |
download | bcm5719-llvm-a0ed165a847103a949ff2dffae38779736a32f54.tar.gz bcm5719-llvm-a0ed165a847103a949ff2dffae38779736a32f54.zip |
Fix <rdar://problem/6261178> clang-on-xcode: [sema] multiple method warning is over enthusiastic.
Fix <rdar://problem/6265257> warnings for ambiguous message send swamp other warnings.
Reworked Sema::MatchTwoMethodDeclarations() to optionally match based on method size and alignment (the default in GCC). Changed Sema::LookupInstanceMethodInGlobalPool() to use this feature.
Added -Wno-struct-selector-match to driver, however didn't hook it up yet. Added a FIXME that says this.
llvm-svn: 57898
Diffstat (limited to 'clang/test/SemaObjC/method-lookup-3.m')
-rw-r--r-- | clang/test/SemaObjC/method-lookup-3.m | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/clang/test/SemaObjC/method-lookup-3.m b/clang/test/SemaObjC/method-lookup-3.m index a1815fa386e..25299ca6d3b 100644 --- a/clang/test/SemaObjC/method-lookup-3.m +++ b/clang/test/SemaObjC/method-lookup-3.m @@ -22,9 +22,9 @@ typedef struct { int x; } Alternate; -(void) x; // expected-warning{{also found}} -(void) y; // expected-warning{{also found}} -(void) z; // expected-warning{{also found}} --(void) setX: (INTERFERE_TYPE) arg; // expected-warning{{also found}} --(void) setY: (INTERFERE_TYPE) arg; // expected-warning{{also found}} --(void) setZ: (INTERFERE_TYPE) arg; // expected-warning{{also found}} +-(void) setX: (INTERFERE_TYPE) arg; +-(void) setY: (INTERFERE_TYPE) arg; +-(void) setZ: (INTERFERE_TYPE) arg; @end void f0(id a0) { @@ -40,13 +40,13 @@ void f2(id a0) { } void f3(id a0, Abstract *a1) { - [ a0 setX: a1]; // expected-warning {{multiple methods named 'setX:' found}} + [ a0 setX: a1]; } void f4(id a0, Abstract *a1) { - [ a0 setY: a1]; // expected-warning {{multiple methods named 'setY:' found}} + [ a0 setY: a1]; } void f5(id a0, Abstract *a1) { - [ a0 setZ: a1]; // expected-warning {{multiple methods named 'setZ:' found}} + [ a0 setZ: a1]; } |