xref: /minix3/external/bsd/llvm/dist/clang/test/Driver/visibility.cpp (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1f4a2713aSLionel Sambuc // RUN: %clang -### -S -fvisibility=hidden -fvisibility=default %s 2> %t.log
2f4a2713aSLionel Sambuc // RUN: FileCheck -check-prefix=CHECK-1 %s < %t.log
3*0a6a1f1dSLionel Sambuc // CHECK-1-NOT: "-ftype-visibility"
4f4a2713aSLionel Sambuc // CHECK-1: "-fvisibility" "default"
5*0a6a1f1dSLionel Sambuc // CHECK-1-NOT: "-ftype-visibility"
6f4a2713aSLionel Sambuc 
7f4a2713aSLionel Sambuc // RUN: %clang -### -S -fvisibility=default -fvisibility=hidden %s 2> %t.log
8f4a2713aSLionel Sambuc // RUN: FileCheck -check-prefix=CHECK-2 %s < %t.log
9*0a6a1f1dSLionel Sambuc // CHECK-2-NOT: "-ftype-visibility"
10f4a2713aSLionel Sambuc // CHECK-2: "-fvisibility" "hidden"
11*0a6a1f1dSLionel Sambuc // CHECK-2-NOT: "-ftype-visibility"
12f4a2713aSLionel Sambuc 
13f4a2713aSLionel Sambuc // RUN: %clang -### -S -fvisibility-ms-compat -fvisibility=hidden %s 2> %t.log
14f4a2713aSLionel Sambuc // RUN: FileCheck -check-prefix=CHECK-3 %s < %t.log
15*0a6a1f1dSLionel Sambuc // CHECK-3-NOT: "-ftype-visibility"
16f4a2713aSLionel Sambuc // CHECK-3: "-fvisibility" "hidden"
17*0a6a1f1dSLionel Sambuc // CHECK-3-NOT: "-ftype-visibility"
18f4a2713aSLionel Sambuc 
19f4a2713aSLionel Sambuc // RUN: %clang -### -S -fvisibility-ms-compat -fvisibility=default %s 2> %t.log
20f4a2713aSLionel Sambuc // RUN: FileCheck -check-prefix=CHECK-4 %s < %t.log
21*0a6a1f1dSLionel Sambuc // CHECK-4-NOT: "-ftype-visibility"
22f4a2713aSLionel Sambuc // CHECK-4: "-fvisibility" "default"
23*0a6a1f1dSLionel Sambuc // CHECK-4-NOT: "-ftype-visibility"
24f4a2713aSLionel Sambuc 
25f4a2713aSLionel Sambuc // RUN: %clang -### -S -fvisibility=hidden -fvisibility-ms-compat %s 2> %t.log
26f4a2713aSLionel Sambuc // RUN: FileCheck -check-prefix=CHECK-5 %s < %t.log
27f4a2713aSLionel Sambuc // CHECK-5: "-fvisibility" "hidden"
28f4a2713aSLionel Sambuc // CHECK-5: "-ftype-visibility" "default"
29f4a2713aSLionel Sambuc 
30f4a2713aSLionel Sambuc // RUN: %clang -### -S -fvisibility=default -fvisibility-ms-compat %s 2> %t.log
31f4a2713aSLionel Sambuc // RUN: FileCheck -check-prefix=CHECK-6 %s < %t.log
32f4a2713aSLionel Sambuc // CHECK-6: "-fvisibility" "hidden"
33f4a2713aSLionel Sambuc // CHECK-6: "-ftype-visibility" "default"
34f4a2713aSLionel Sambuc 
35