YouCompleteMe/cpp/llvm/tools/clang/test/SemaObjC/method-lookup-2.m
Strahinja Val Markovic 1f51a89d39 Adding more llvm/clang files
These were ignored by git accidentally. We want ALL OF THEM since they all came
in the llvm/clang source distribution.
2012-07-05 17:55:45 -07:00

64 lines
1.2 KiB
Objective-C

// RUN: %clang_cc1 -fsyntax-only -verify %s
typedef signed char BOOL;
@protocol NSObject
+ alloc;
- init;
- (BOOL) isEqual:(id) object;
- (Class)class;
@end
@interface NSObject < NSObject > {} @end
@class NSString, NSPort;
@interface NSPortNameServer:NSObject
+ (NSPortNameServer *) systemDefaultPortNameServer;
@end
@interface NSMachBootstrapServer:NSPortNameServer + (id) sharedInstance; @end
enum {
NSWindowsNTOperatingSystem = 1, NSWindows95OperatingSystem, NSSolarisOperatingSystem, NSHPUXOperatingSystem, NSMACHOperatingSystem, NSSunOSOperatingSystem, NSOSF1OperatingSystem
};
@interface NSRunLoop:NSObject {} @end
@interface NSRunLoop(NSRunLoopConveniences)
- (void) run;
@end
extern NSString *const NSWillBecomeMultiThreadedNotification;
@interface SenTestTool:NSObject {}
@end
@implementation SenTestTool
+ (void) initialize {}
+(SenTestTool *) sharedInstance { return 0; }
-(int) run { return 0; }
+(int) run {
return[[self sharedInstance] run];
}
@end
@interface XX : NSObject
+ classMethod;
@end
@interface YY : NSObject
- whatever;
@end
@implementation YY
- whatever {
id obj = [[XX alloc] init];
[[obj class] classMethod];
return 0;
}
@end