1 // Option should not be passed to the frontend by default.
2 // RUN: %clang -target x86_64-apple-macosx10.15-gnu -fsanitize=address %s \
5 // CHECK-NOT: -fsanitize-address-use-after-return
7 // RUN: %clang -target x86_64-apple-macosx10.15-gnu -fsanitize=address \
8 // RUN: -fsanitize-address-use-after-return=never %s -### 2>&1 | \
9 // RUN: FileCheck -check-prefix=CHECK-NEVER-ARG %s
10 // CHECK-NEVER-ARG: "-fsanitize-address-use-after-return=never"
12 // RUN: %clang -target x86_64-apple-macosx10.15-gnu -fsanitize=address \
13 // RUN: -fsanitize-address-use-after-return=runtime %s -### 2>&1 | \
14 // RUN: FileCheck -check-prefix=CHECK-RUNTIME %s
15 // CHECK-RUNTIME: "-fsanitize-address-use-after-return=runtime"
17 // RUN: %clang -target x86_64-apple-macosx10.15-gnu -fsanitize=address \
18 // RUN: -fsanitize-address-use-after-return=always %s -### 2>&1 | \
19 // RUN: FileCheck -check-prefix=CHECK-ALWAYS-ARG %s
21 // RUN: %clang -target x86_64-apple-macosx10.15-gnu -fsanitize=address \
22 // RUN: -fsanitize-address-use-after-return=never \
23 // RUN: -fsanitize-address-use-after-return=always %s -### 2>&1 | \
24 // RUN: FileCheck -check-prefix=CHECK-ALWAYS-ARG %s
25 // CHECK-ALWAYS-ARG: "-fsanitize-address-use-after-return=always"
27 // RUN: not %clang -target x86_64-apple-macosx10.15-gnu -fsanitize=address \
28 // RUN: -fsanitize-address-use-after-return=bad_arg %s -### 2>&1 | \
29 // RUN: FileCheck -check-prefix=CHECK-INVALID-ARG %s
30 // CHECK-INVALID-ARG: error: unsupported argument 'bad_arg' to option '-fsanitize-address-use-after-return='