`-arch` is a Darwin-specific option that is ignored for other targets and not known by GCC. ``` % clang -arch arm64 -c a.c clang: warning: argument unused during compilation: '-arch arm64' [-Wunused-command-line-argument] ``` We are utilizing TargetSpecific (from https://reviews.llvm.org/D151590) to make more options lead to errors for unsupported targets.
6 lines
334 B
Matlab
6 lines
334 B
Matlab
// RUN: %clang -### -x objective-c --target=x86_64-apple-macos10.6 -fobjc-arc -fsyntax-only %s 2> %t.log
|
|
// RUN: grep objective-c %t.log
|
|
// RUN: not grep "fobjc-arc-exceptions" %t.log
|
|
// RUN: %clang -### -x objective-c++ --target=x86_64-apple-macos10.6 -fobjc-arc -fsyntax-only %s 2> %t.log
|
|
// RUN: grep "fobjc-arc-exceptions" %t.log
|