1 | // RUN: %clang_cc1 -x objective-c++ -Wno-return-type -fblocks -fms-extensions -rewrite-objc -fobjc-runtime=macosx-fragile-10.5 %s -o %t-rw.cpp |
2 | // RUN: %clang_cc1 -fsyntax-only -std=gnu++98 -Wno-address-of-temporary -Did="void *" -D"SEL=void*" -D"__declspec(X)=" %t-rw.cpp |
3 | // radar 9254348 |
4 | // RUN: %clang_cc1 -x objective-c++ -Wno-return-type -fblocks -fms-extensions -rewrite-objc %s -o %t-modern-rw.cpp |
5 | // RUN: %clang_cc1 -fsyntax-only -std=gnu++98 -Wno-address-of-temporary -Did="void *" -D"SEL=void*" -D"__declspec(X)=" %t-modern-rw.cpp |
6 | // rdar://11259664 |
7 | |
8 | // rdar://11375908 |
9 | typedef unsigned long size_t; |
10 | |
11 | void *sel_registerName(const char *); |
12 | typedef void (^BLOCK_TYPE)(void); |
13 | |
14 | @interface CoreDAVTaskGroup |
15 | { |
16 | int IVAR; |
17 | } |
18 | @property int IVAR; |
19 | - (void) setCompletionBlock : (BLOCK_TYPE) arg; |
20 | @end |
21 | |
22 | @implementation CoreDAVTaskGroup |
23 | - (void)_finishInitialSync { |
24 | CoreDAVTaskGroup *folderPost; |
25 | folderPost.completionBlock = ^{ |
26 | self.IVAR = 0; |
27 | [self _finishInitialSync]; |
28 | }; |
29 | |
30 | [folderPost setCompletionBlock : (^{ |
31 | self.IVAR = 0; |
32 | })]; |
33 | } |
34 | @dynamic IVAR; |
35 | - (void) setCompletionBlock : (BLOCK_TYPE) arg {} |
36 | @end |
37 | |
38 | |
39 | |