OSDN Git Service

gcc/:
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.dg / warn / Wunused-var-6.C
1 // { dg-do compile }
2 // { dg-options "-Wunused" }
3
4 template <int N>
5 int
6 f1 (void)
7 {
8   int c = ({
9     int a;
10     a = 1;
11     a; });
12   return c;
13 }
14
15 template <int N>
16 void
17 f2 (void)
18 {
19   int f;
20   f = 0;
21   __asm__ __volatile__ ("" : "+r" (f));
22 }
23
24 void
25 test ()
26 {
27   (void) f1<0> ();
28   f2<0> ();
29 }