xref: /minix3/external/bsd/llvm/dist/clang/test/SemaObjC/property-8.m (revision f4a2713ac843a11c696ec80c0a5e3e5d80b4d338)
1*f4a2713aSLionel Sambuc// RUN: %clang_cc1 -fsyntax-only -verify %s
2*f4a2713aSLionel Sambuc// expected-no-diagnostics
3*f4a2713aSLionel Sambuctypedef signed char BOOL;
4*f4a2713aSLionel Sambuctypedef unsigned int NSUInteger;
5*f4a2713aSLionel Sambuctypedef struct _NSZone NSZone;
6*f4a2713aSLionel Sambuc
7*f4a2713aSLionel Sambuc@class NSInvocation, NSMethodSignature, NSCoder, NSString, NSEnumerator;
8*f4a2713aSLionel Sambuc
9*f4a2713aSLionel Sambuc@protocol NSObject  - (BOOL)isEqual:(id)object; @end
10*f4a2713aSLionel Sambuc@protocol NSCopying  - (id)copyWithZone:(NSZone *)zone; @end
11*f4a2713aSLionel Sambuc@protocol NSMutableCopying  - (id)mutableCopyWithZone:(NSZone *)zone; @end
12*f4a2713aSLionel Sambuc@protocol NSCoding  - (void)encodeWithCoder:(NSCoder *)aCoder; @end
13*f4a2713aSLionel Sambuc
14*f4a2713aSLionel Sambuc@interface NSObject <NSObject> {} @end
15*f4a2713aSLionel Sambuc
16*f4a2713aSLionel Sambuctypedef float CGFloat;
17*f4a2713aSLionel Sambuc
18*f4a2713aSLionel Sambuctypedef enum { NSMinXEdge = 0, NSMinYEdge = 1, NSMaxXEdge = 2, NSMaxYEdge = 3 } NSFastEnumerationState;
19*f4a2713aSLionel Sambuc
20*f4a2713aSLionel Sambuc@protocol NSFastEnumeration
21*f4a2713aSLionel Sambuc- (NSUInteger)countByEnumeratingWithState:(NSFastEnumerationState *)state objects:(id *)stackbuf count:(NSUInteger)len;
22*f4a2713aSLionel Sambuc@end
23*f4a2713aSLionel Sambuc
24*f4a2713aSLionel Sambuc@class NSString;
25*f4a2713aSLionel Sambuc
26*f4a2713aSLionel Sambuc@interface NSDictionary : NSObject <NSCopying, NSMutableCopying, NSCoding, NSFastEnumeration>
27*f4a2713aSLionel Sambuc- (NSUInteger)count;
28*f4a2713aSLionel Sambuc@end
29*f4a2713aSLionel Sambuc
30*f4a2713aSLionel Sambucextern NSString * const NSBundleDidLoadNotification;
31*f4a2713aSLionel Sambuc
32*f4a2713aSLionel Sambuc@interface NSObject(NSKeyValueObserving)
33*f4a2713aSLionel Sambuc- (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context;
34*f4a2713aSLionel Sambuc- (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath;
35*f4a2713aSLionel Sambuc@end
36*f4a2713aSLionel Sambuc
37*f4a2713aSLionel Sambucenum { NSCaseInsensitivePredicateOption = 0x01,     NSDiacriticInsensitivePredicateOption = 0x02 };
38*f4a2713aSLionel Sambuc
39*f4a2713aSLionel Sambuc@interface NSResponder : NSObject <NSCoding> {}
40*f4a2713aSLionel Sambuc@end
41*f4a2713aSLionel Sambuc
42*f4a2713aSLionel Sambucextern NSString * const NSFullScreenModeAllScreens;
43*f4a2713aSLionel Sambuc@interface NSWindowController : NSResponder <NSCoding> {}
44*f4a2713aSLionel Sambuc@end
45*f4a2713aSLionel Sambuc
46*f4a2713aSLionel Sambucextern NSString *NSAlignmentBinding ;
47*f4a2713aSLionel Sambuc
48*f4a2713aSLionel Sambuc@interface _XCOQQuery : NSObject {}
49*f4a2713aSLionel Sambuc@end
50*f4a2713aSLionel Sambuc
51*f4a2713aSLionel Sambucextern NSString *PBXWindowDidChangeFirstResponderNotification;
52*f4a2713aSLionel Sambuc
53*f4a2713aSLionel Sambuc@interface PBXModule : NSWindowController {}
54*f4a2713aSLionel Sambuc@end
55*f4a2713aSLionel Sambuc
56*f4a2713aSLionel Sambuc@class _XCOQHelpTextBackgroundView;
57*f4a2713aSLionel Sambuc@interface PBXOpenQuicklyModule : PBXModule
58*f4a2713aSLionel Sambuc{
59*f4a2713aSLionel Sambuc@private
60*f4a2713aSLionel Sambuc  _XCOQQuery *_query;
61*f4a2713aSLionel Sambuc}
62*f4a2713aSLionel Sambuc@end
63*f4a2713aSLionel Sambuc
64*f4a2713aSLionel Sambuc@interface PBXOpenQuicklyModule ()
65*f4a2713aSLionel Sambuc@property(readwrite, retain) _XCOQQuery *query;
66*f4a2713aSLionel Sambuc@end
67*f4a2713aSLionel Sambuc
68*f4a2713aSLionel Sambuc@implementation PBXOpenQuicklyModule
69*f4a2713aSLionel Sambuc@synthesize query = _query;
70*f4a2713aSLionel Sambuc- (void) _clearQuery
71*f4a2713aSLionel Sambuc{
72*f4a2713aSLionel Sambuc  [self.query removeObserver: self forKeyPath: @"matches"];
73*f4a2713aSLionel Sambuc}
74*f4a2713aSLionel Sambuc@end
75*f4a2713aSLionel Sambuc
76