diff options
-rw-r--r-- | include/clang/Basic/DiagnosticSemaKinds.td | 3 | ||||
-rw-r--r-- | test/SemaObjC/arc.m | 17 |
2 files changed, 18 insertions, 2 deletions
diff --git a/include/clang/Basic/DiagnosticSemaKinds.td b/include/clang/Basic/DiagnosticSemaKinds.td index 97a136f895..ab4a843e14 100644 --- a/include/clang/Basic/DiagnosticSemaKinds.td +++ b/include/clang/Basic/DiagnosticSemaKinds.td @@ -2998,8 +2998,7 @@ def err_arc_method_not_found : Error< def err_arc_receiver_forward_class : Error< "receiver %0 for class message is a forward declaration">; def err_arc_may_not_respond : Error< - "receiver type %0 for instance message does not declare a method with " - "selector %1">; + "no visible @interface for %0 declares the selector %1">; def err_arc_receiver_forward_instance : Error< "receiver type %0 for instance message is a forward declaration">; def err_arc_collection_forward : Error< diff --git a/test/SemaObjC/arc.m b/test/SemaObjC/arc.m index dc5a1fe922..ed6e60d8dc 100644 --- a/test/SemaObjC/arc.m +++ b/test/SemaObjC/arc.m @@ -668,3 +668,20 @@ void test38() { void _NSCalc(NSColor* color, NSColor* bezelColors[]) __attribute__((unavailable("not available in automatic reference counting mode"))); void _NSCalcBeze(NSColor* color, NSColor* bezelColors[]); // expected-error {{must explicitly describe intended ownership of an object array parameter}} + +// rdar://9970739 +@interface RestaurantTableViewCell +- (void) restaurantLocation; +@end + +@interface Radar9970739 +- (void) Meth; +@end + +@implementation Radar9970739 +- (void) Meth { + RestaurantTableViewCell *cell; + [cell restaurantLocatoin]; // expected-error {{no visible @interface for 'RestaurantTableViewCell' declares the selector 'restaurantLocatoin'}} +} +@end + |