1// RUN: %clang_cc1 -Wno-unused -fblocks -fobjc-exceptions -ast-dump -ast-dump-filter Test %s | FileCheck -strict-whitespace %s 2 3void TestBlockExpr(int x) { 4 ^{ x; }; 5} 6// CHECK: FunctionDecl{{.*}}TestBlockExpr 7// CHECK: BlockExpr{{.*}} 'void (^)(void)' 8// CHECK-NEXT: BlockDecl 9 10void TestExprWithCleanup(int x) { 11 ^{ x; }; 12} 13// CHECK: FunctionDecl{{.*}}TestExprWithCleanup 14// CHECK: ExprWithCleanups 15// CHECK-NEXT: cleanup Block 16// CHECK-NEXT: BlockExpr 17 18@interface A 19@end 20 21void TestObjCAtCatchStmt() { 22 @try { 23 } @catch(A *a) { 24 } @catch(...) { 25 } @finally { 26 } 27} 28// CHECK: FunctionDecl{{.*}}TestObjCAtCatchStmt 29// CHECK: ObjCAtTryStmt 30// CHECK-NEXT: CompoundStmt 31// CHECK-NEXT: ObjCAtCatchStmt{{.*}} 32// CHECK-NEXT: VarDecl{{.*}}a 33// CHECK-NEXT: CompoundStmt 34// CHECK-NEXT: ObjCAtCatchStmt{{.*}} catch all 35// CHECK-NEXT: CompoundStmt 36// CHECK-NEXT: ObjCAtFinallyStmt 37