teak-llvm/clang/test/FixIt/selector-fixit.m
Fariborz Jahanian 4cc5552b9b Objective-C [qoi]: privide typo correction for selectors
in addition of receiver having static type, but also when
receiver has dynamic type (of 'id' variety) as well as when
receiver is of 'Class' type vareity. // rdar://7853549

llvm-svn: 184195
2013-06-18 15:31:36 +00:00

42 lines
751 B
Objective-C

// RUN: cp %s %t
// RUN: %clang_cc1 -x objective-c -Wundeclared-selector -fixit %t
// RUN: %clang_cc1 -x objective-c -Wundeclared-selector -Werror %t
// rdar://14039037
@interface NSObject @end
@interface LogoutController : NSObject
- (void)close;
- (void)closed;
- (void) open : (id) file_id;
@end
@implementation LogoutController
- (void)close { }
- (void)closed { }
- (SEL)Meth
{
return @selector(cloze);
}
- (void) open : (id) file_id {}
- (SEL)Meth1
{
return @selector(ope:);
}
@end
// rdar://7853549
@interface rdar7853549 : NSObject
- (int) bounds;
@end
@implementation rdar7853549
- (int) bounds { return 0; }
- (void)PrivateMeth { int bounds = [self bonds]; }
- (void)OtherPrivateMeth : (id) p { int bounds = [p bonds]; }
@end