1 /* PR middle-end/20303 */
2 /* Test nesting of #pragma GCC visibility. */
3 /* { dg-do compile } */
4 /* { dg-require-visibility "" } */
5 /* { dg-final { scan-not-hidden "foo00" } } */
6 /* { dg-final { scan-hidden "foo01" } } */
7 /* { dg-final { scan-not-hidden "foo02" } } */
8 /* { dg-final { scan-hidden "foo03" } } */
9 /* { dg-final { scan-not-hidden "foo04" } } */
10 /* { dg-final { scan-not-hidden "foo05" } } */
11 /* { dg-final { scan-not-hidden "foo06" } } */
12 /* { dg-final { scan-hidden "foo07" } } */
13 /* { dg-final { scan-not-hidden "foo08" } } */
14 /* { dg-final { scan-hidden "foo09" } } */
15 /* { dg-final { scan-not-hidden "foo10" } } */
16 /* { dg-final { scan-hidden "foo11" } } */
17 /* { dg-final { scan-hidden "foo12" } } */
18 /* { dg-final { scan-hidden "foo13" } } */
19 /* { dg-final { scan-not-hidden "foo14" } } */
20 /* { dg-final { scan-hidden "foo15" } } */
21 /* { dg-final { scan-not-hidden "foo16" } } */
22 /* { dg-final { scan-hidden "foo17" } } */
23 /* { dg-final { scan-not-hidden "foo18" } } */
24 /* { dg-final { scan-hidden "foo19" } } */
25 /* { dg-final { scan-not-hidden "foo20" } } */
26 /* { dg-final { scan-hidden "foo21" } } */
27 /* { dg-final { scan-not-hidden "foo22" } } */
28 /* { dg-final { scan-hidden "foo23" } } */
29 /* { dg-final { scan-not-hidden "foo24" } } */
30 /* { dg-final { scan-hidden "foo25" } } */
31 /* { dg-final { scan-not-hidden "foo26" } } */
32 /* { dg-final { scan-hidden "foo27" } } */
33 /* { dg-final { scan-not-hidden "foo28" } } */
34 /* { dg-final { scan-hidden "foo29" } } */
35 /* { dg-final { scan-not-hidden "foo30" } } */
36 /* { dg-final { scan-hidden "foo31" } } */
37 /* { dg-final { scan-not-hidden "foo32" } } */
38 /* { dg-final { scan-hidden "foo33" } } */
39 /* { dg-final { scan-not-hidden "foo34" } } */
40 /* { dg-final { scan-hidden "foo35" } } */
41 /* { dg-final { scan-not-hidden "foo36" } } */
42 /* { dg-final { scan-hidden "foo37" } } */
43 /* { dg-final { scan-not-hidden "foo38" } } */
44 /* { dg-final { scan-hidden "foo39" } } */
45 /* { dg-final { scan-not-hidden "foo40" } } */
46 /* { dg-final { scan-hidden "foo41" } } */
47 /* { dg-final { scan-not-hidden "foo42" } } */
48 /* { dg-final { scan-hidden "foo43" } } */
49 /* { dg-final { scan-not-hidden "foo44" } } */
50 /* { dg-final { scan-hidden "foo45" } } */
51 /* { dg-final { scan-hidden "foo46" } } */
52 /* { dg-final { scan-hidden "foo47" } } */
53 /* { dg-final { scan-not-hidden "foo48" } } */
54 /* { dg-final { scan-hidden "foo49" } } */
55 /* { dg-final { scan-not-hidden "foo50" } } */
56 /* { dg-final { scan-hidden "foo51" } } */
57 /* { dg-final { scan-not-hidden "foo52" } } */
58 /* { dg-final { scan-not-hidden "foo53" } } */
59 /* { dg-final { scan-not-hidden "foo54" } } */
60 /* { dg-final { scan-hidden "foo55" } } */
61 /* { dg-final { scan-not-hidden "foo56" } } */
62 /* { dg-final { scan-hidden "foo57" } } */
63 /* { dg-final { scan-not-hidden "foo58" } } */
64 /* { dg-final { scan-hidden "foo59" } } */
66 #pragma GCC visibility push(default)
68 #pragma GCC visibility push(hidden)
70 #pragma GCC visibility push(default)
72 #pragma GCC visibility push(hidden)
74 #pragma GCC visibility push(default)
76 #pragma GCC visibility push(default)
78 #pragma GCC visibility push(default)
80 #pragma GCC visibility push(hidden)
82 #pragma GCC visibility push(default)
84 #pragma GCC visibility push(hidden)
86 #pragma GCC visibility push(default)
88 #pragma GCC visibility push(hidden)
90 #pragma GCC visibility push(hidden)
92 #pragma GCC visibility push(hidden)
94 #pragma GCC visibility push(default)
96 #pragma GCC visibility push(hidden)
98 #pragma GCC visibility push(default)
100 #pragma GCC visibility push(hidden)
102 #pragma GCC visibility push(default)
104 #pragma GCC visibility push(hidden)
106 #pragma GCC visibility push(default)
108 #pragma GCC visibility push(hidden)
110 #pragma GCC visibility push(default)
112 #pragma GCC visibility push(hidden)
114 #pragma GCC visibility push(default)
116 #pragma GCC visibility push(hidden)
118 #pragma GCC visibility push(default)
120 #pragma GCC visibility push(hidden)
122 #pragma GCC visibility push(default)
124 #pragma GCC visibility push(hidden)
126 #pragma GCC visibility pop
128 #pragma GCC visibility pop
130 #pragma GCC visibility pop
132 #pragma GCC visibility pop
134 #pragma GCC visibility pop
136 #pragma GCC visibility pop
138 #pragma GCC visibility pop
140 #pragma GCC visibility pop
142 #pragma GCC visibility pop
144 #pragma GCC visibility pop
146 #pragma GCC visibility pop
148 #pragma GCC visibility pop
150 #pragma GCC visibility pop
152 #pragma GCC visibility pop
154 #pragma GCC visibility pop
156 #pragma GCC visibility pop
158 #pragma GCC visibility pop
160 #pragma GCC visibility pop
162 #pragma GCC visibility pop
164 #pragma GCC visibility pop
166 #pragma GCC visibility pop
168 #pragma GCC visibility pop
170 #pragma GCC visibility pop
172 #pragma GCC visibility pop
174 #pragma GCC visibility pop
176 #pragma GCC visibility pop
178 #pragma GCC visibility pop
180 #pragma GCC visibility pop
182 #pragma GCC visibility pop
184 #pragma GCC visibility push (hidden)
186 #pragma GCC visibility pop
187 #pragma GCC visibility pop
190 void foo##N##0() { } \
191 void foo##N##1() { } \
192 void foo##N##2() { } \
193 void foo##N##3() { } \
194 void foo##N##4() { } \
195 void foo##N##5() { } \
196 void foo##N##6() { } \
197 void foo##N##7() { } \
198 void foo##N##8() { } \