]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - test/Rewriter/rewrite-modern-block-consts.mm
Fix-up EOL-styles changed by upstream.
[FreeBSD/FreeBSD.git] / test / Rewriter / rewrite-modern-block-consts.mm
1 // RUN: %clang_cc1 -x objective-c++ -Wno-return-type -fblocks -fms-extensions -rewrite-objc %s -o %t-modern-rw.cpp
2 // RUN: %clang_cc1 -fsyntax-only -Werror -Wno-address-of-temporary -U__declspec -D"__declspec(X)=" %t-modern-rw.cpp
3 // rdar:// 8243071
4
5 // rdar://11375908
6 typedef unsigned long size_t;
7
8 void x(int y) {}
9 void f() {
10     const int bar = 3;
11     int baz = 4;
12     __block int bab = 4;
13     __block const int bas = 5;
14     void (^b)() = ^{
15         x(bar);
16         x(baz);
17         x(bab);
18         x(bas);
19         b();
20     };
21     b();
22