30 lines · plain
1// Test without serialization:2// RUN: %clang_cc1 -triple x86_64-pc-linux -ast-dump %s \3// RUN: | FileCheck --strict-whitespace %s4 5// Test with serialization:6// RUN: %clang_cc1 -triple x86_64-pc-linux -emit-pch -o %t %s7// RUN: %clang_cc1 -x objective-c -triple x86_64-pc-linux -include-pch %t -ast-dump-all /dev/null \8// RUN: | sed -e "s/ <undeserialized declarations>//" -e "s/ imported//" \9// RUN: | FileCheck --strict-whitespace %s10 11 12@interface Adder13- (float) sum: (float)x with: (float)y __attribute((optnone));14@end15 16#pragma float_control(precise, off)17 18@implementation Adder19- (float) sum: (float)x with: (float)y __attribute((optnone)) {20 return x + y;21}22 23@end24 25// CHECK-LABEL: ObjCImplementationDecl {{.*}} Adder26// CHECK: ObjCMethodDecl {{.*}} - sum:with: 'float'27// CHECK: CompoundStmt {{.*}} FPContractMode=1 MathErrno=128// CHECK-NEXT: ReturnStmt29// CHECK-NEXT: BinaryOperator {{.*}} 'float' '+' FPContractMode=1 MathErrno=130