Merged revisions 208012,208018-208019,208021,208023-208030,208033,208037,208040-20804...
[official-gcc.git] / main / gcc / testsuite / g++.dg / cpp0x / gen-attrs-4.C
blobeb585a89be45b3d14e05c12a6d9a060b45bf94d6
1 // { dg-options "-Wunused -pedantic-errors" }
2 // { dg-do compile { target c++11 } }
3 // Test for syntax support of various attribute permutations.
5 int
6 [[noreturn]] // { dg-warning "ignored" }
7 one
8 [[gnu::unused]]
9 (void);
11 int one_third [[noreturn]] [[gnu::unused]] (void);
13 int [[gnu::unused]] one_half(); // { dg-warning "ignored" }
15 static
16 [[noreturn]] // { dg-warning "ignored" }
17 void two [[gnu::unused]] (void) {}
21 [[gnu::unused]]
22 int
23 five(void)
24 [[noreturn]] // { dg-warning "ignored" }
27 [[noreturn]]
28 void
29 six (void)