blob: 85cfcd8254950a13f81d8eac4a30b2359605c87d [file] [log] [blame]
John McCallfbe5ed72015-11-05 19:19:56 +00001// Check miscellaneous Objective-C options.
2
Alex Lorenz1acc63f2017-12-19 19:05:04 +00003// RUN: %clang -target x86_64-apple-macosx10.7 -S -### %s -fobjc-arc -fobjc-weak 2>&1 | FileCheck %s --check-prefix ARC-WEAK
4// RUN: %clang -target x86_64-apple-macosx10.7 -S -### %s -fno-objc-weak -fobjc-weak -fobjc-arc 2>&1 | FileCheck %s --check-prefix ARC-WEAK
John McCallfbe5ed72015-11-05 19:19:56 +00005// ARC-WEAK: -fobjc-arc
6// ARC-WEAK: -fobjc-weak
7
Alex Lorenz1acc63f2017-12-19 19:05:04 +00008// RUN: %clang -target x86_64-apple-macos10.7 -S -### %s -fobjc-arc -fno-objc-weak 2>&1 | FileCheck %s --check-prefix ARC-NO-WEAK
9// RUN: %clang -target x86_64-apple-macos10.7 -S -### %s -fobjc-weak -fno-objc-weak -fobjc-arc 2>&1 | FileCheck %s --check-prefix ARC-NO-WEAK
John McCallfbe5ed72015-11-05 19:19:56 +000010// ARC-NO-WEAK: -fobjc-arc
11// ARC-NO-WEAK: -fno-objc-weak
12
Alex Lorenz1acc63f2017-12-19 19:05:04 +000013// RUN: %clang -target x86_64-apple-macosx10.5 -S -### %s -fobjc-arc -fobjc-weak 2>&1 | FileCheck %s --check-prefix ARC-WEAK-NOTSUPPORTED
14// RUN: %clang -target x86_64-apple-macosx10.5 -S -### %s -fno-objc-weak -fobjc-weak -fobjc-arc 2>&1 | FileCheck %s --check-prefix ARC-WEAK-NOTSUPPORTED
Greg Parker084f2312016-04-02 05:29:00 +000015// ARC-WEAK-NOTSUPPORTED: error: -fobjc-weak is not supported on the current deployment target
John McCallfbe5ed72015-11-05 19:19:56 +000016
Alex Lorenz1acc63f2017-12-19 19:05:04 +000017// RUN: %clang -target x86_64-apple-macos10.7 -S -### %s -fobjc-weak 2>&1 | FileCheck %s --check-prefix MRC-WEAK
18// RUN: %clang -target x86_64-apple-macos10.7 -S -### %s -fno-objc-weak -fobjc-weak 2>&1 | FileCheck %s --check-prefix MRC-WEAK
John McCallfbe5ed72015-11-05 19:19:56 +000019// MRC-WEAK: -fobjc-weak
20
Alex Lorenz1acc63f2017-12-19 19:05:04 +000021// RUN: %clang -target x86_64-apple-macosx10.7 -S -### %s -fno-objc-weak 2>&1 | FileCheck %s --check-prefix MRC-NO-WEAK
22// RUN: %clang -target x86_64-apple-macosx10.7 -S -### %s -fobjc-weak -fno-objc-weak 2>&1 | FileCheck %s --check-prefix MRC-NO-WEAK
John McCallfbe5ed72015-11-05 19:19:56 +000023// MRC-NO-WEAK: -fno-objc-weak
24
Alex Lorenz1acc63f2017-12-19 19:05:04 +000025// RUN: %clang -target x86_64-apple-macosx10.5 -S -### %s -fobjc-weak 2>&1 | FileCheck %s --check-prefix MRC-WEAK-NOTSUPPORTED
26// RUN: %clang -target x86_64-apple-macosx10.5 -S -### %s -fno-objc-weak -fobjc-weak 2>&1 | FileCheck %s --check-prefix MRC-WEAK-NOTSUPPORTED
Greg Parker084f2312016-04-02 05:29:00 +000027// MRC-WEAK-NOTSUPPORTED: error: -fobjc-weak is not supported on the current deployment target