This adds -no-opaque-pointers to clang tests whose output will change when opaque pointers are enabled by default. This is intended to be part of the migration approach described in https://discourse.llvm.org/t/enabling-opaque-pointers-by-default/61322/9. The patch has been produced by replacing %clang_cc1 with %clang_cc1 -no-opaque-pointers for tests that fail with opaque pointers enabled. Worth noting that this doesn't cover all tests, there's a remaining ~40 tests not using %clang_cc1 that will need a followup change. Differential Revision: https://reviews.llvm.org/D123115
23 lines
750 B
Plaintext
23 lines
750 B
Plaintext
// RUN: %clang_cc1 -no-opaque-pointers -triple x86_64-apple-darwin10 -emit-llvm -fobjc-arc -o - %s | FileCheck %s
|
|
// rdar://10139365
|
|
|
|
@interface Test58
|
|
- (char* &) interior __attribute__((objc_returns_inner_pointer));
|
|
- (int&)reference_to_interior_int __attribute__((objc_returns_inner_pointer));
|
|
@end
|
|
|
|
void foo() {
|
|
Test58 *ptr;
|
|
char *c = [(ptr) interior];
|
|
|
|
int i = [(ptr) reference_to_interior_int];
|
|
}
|
|
|
|
// CHECK: [[T0:%.*]] = load {{%.*}} {{%.*}}, align 8
|
|
// CHECK: [[T1:%.*]] = bitcast {{%.*}} [[T0]] to i8*
|
|
// call i8* @llvm.objc.retainAutorelease(i8* [[T1]]) nounwind
|
|
// CHECK: [[T2:%.*]] = load {{%.*}} {{%.*}}, align 8
|
|
// CHECK: [[T3:%.*]] = bitcast {{%.*}} [[T2]] to i8*
|
|
// call i8* @llvm.objc.retainAutorelease(i8* [[T3]]) nounwind
|
|
|