1 // RUN: %clang_cc1 -fsyntax-only -verify -triple i686-apple-darwin9 -Wno-objc-root-class %s
2 // expected-no-diagnostics
3 // FIXME: must also compile as Objective-C++
5 // <rdar://problem/6487662>
6 typedef struct objc_selector *SEL;
7 typedef signed char BOOL;
8 typedef unsigned int NSUInteger;
9 typedef struct _NSZone NSZone;
10 @class NSInvocation, NSMethodSignature, NSCoder, NSString, NSEnumerator;
12 - (BOOL)isEqual:(id)object;
13 - (BOOL)respondsToSelector:(SEL)aSelector;
16 - (id)copyWithZone:(NSZone *)zone;
18 @protocol NSMutableCopying
19 - (id)mutableCopyWithZone:(NSZone *)zone;
22 - (void)encodeWithCoder:(NSCoder *)aCoder;
24 @interface NSObject <NSObject> {}
26 @class NSString, NSData;
27 typedef struct _NSPoint {}
29 @interface NSString : NSObject <NSCopying, NSMutableCopying, NSCoding>
32 @interface NSMutableString : NSString
33 - (void)replaceCharactersInRange:(NSRange)range withString:(NSString *)aString;
35 @class NSArray, NSDictionary, NSMapTable;
36 @interface NSResponder : NSObject <NSCoding> {}
38 @protocol NSAnimatablePropertyContainer
41 extern NSString *NSAnimationTriggerOrderIn ;
42 @interface NSView : NSResponder <NSAnimatablePropertyContainer> {
43 struct __VFlags2 {} _vFlags2;
46 @class NSAttributedString, NSEvent, NSFont, NSFormatter, NSImage, NSMenu, NSText, NSView;
47 @interface FooiagramView : NSView {
52 @interface _FooiagramViewReserved : NSObject {
54 NSMutableString *_typeToSelectString;
55 struct _FooiagramViewFlags {
56 unsigned int delegateRespondsToPrintInfoForBarView : 1;
60 extern _FooiagramViewReserved *_FooiagramViewBarViewReserved(FooiagramView *BarView);
61 @interface FooiagramView (FooiagramViewPrivate)
62 + (Class)_defaultBarToolManagerClass;
64 @implementation FooiagramView
65 static NSMapTable *_defaultMenuForClass = 0;
66 - (void)setDelegate:(id)delegate {
67 if (_delegate != delegate) {
68 struct _FooiagramViewFlags *dvFlags =
69 &_FooiagramViewBarViewReserved(self)->_dvFlags;
70 if (_delegate != ((void *)0)) {
71 dvFlags->delegateRespondsToPrintInfoForBarView = [_delegate respondsToSelector:@selector(printInfoForBarView:)];
77 // <rdar://problem/6487684>
78 @interface WizKing_MIKeep {
79 struct __LoreStuffNode *_historyStuff;
82 typedef struct __LoreStuffNode {} LoreStuffNode;
83 @implementation WizKing_MIKeep
86 node = &(_historyStuff[1]);
91 // <rdar://problem/6487702>
92 typedef long unsigned int __darwin_size_t;
93 typedef __darwin_size_t size_t;
94 void *memset(void *, int, size_t);
95 @class NSString, NSURL, NSError;
96 @interface OingoWerdnaPeon : NSObject {}
98 OingoPT_SmashOK, OingoPT_NoSuchFile, }
99 OingoWerdnaPeonIOMethod;
100 @interface OingoWerdnaPeonSmashDrivel : NSObject <NSCopying> {}
102 @interface OingoBoingoContraptionPeon : OingoWerdnaPeon {
103 struct _OingoBoingoContraptionPeonFlags {}
107 @implementation OingoBoingoContraptionPeon
108 + (void)initialize {}
109 - (id)initWithSmashDrivel:(OingoWerdnaPeonSmashDrivel *)info {
110 if (self != ((void *)0)) {
111 (void)memset(&_nfttFlags, 0, sizeof(struct _OingoBoingoContraptionPeonFlags));
126 struct X *xp = &value;