left->getResultType(), right->getResultType()))
return false;
+ // If either is hidden, it is not considered to match.
+ if (left->isHidden() || right->isHidden())
+ return false;
+
if (getLangOpts().ObjCAutoRefCount &&
(left->hasAttr<NSReturnsRetainedAttr>()
!= right->hasAttr<NSReturnsRetainedAttr>() ||
@interface A (Sub)
- (char)method3;
+- (char*)method4;
@end
@interface B (Sub)
- (char *)method3;
+- (char*)method4;
@end
module MethodPoolA {
header "MethodPoolA.h"
+ explicit module Sub2 {
+ header "MethodPoolASub2.h"
+ }
+
explicit module Sub {
header "MethodPoolASub.h"
}
[object method2:1];
}
+void testMethod4(id object) {
+ [object method4]; // expected-warning{{instance method '-method4' not found (return type defaults to 'id')}}
+}
+
@import MethodPoolB;
void testMethod1Again(id object) {
// expected-note@2{{using}}
// expected-note@2{{also found}}
}
+
+void testMethod4Again(id object) {
+ [object method4];
+}