OSDN Git Service

PR c++/53549
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.dg / torture / pr33887-3.C
1 /* { dg-do run } */
2
3 extern "C" void abort (void);
4
5 struct s
6 {
7   unsigned long long f1 : 40;
8   unsigned int f2 : 24;
9 };
10
11 s sv;
12
13 void __attribute__((noinline)) foo(unsigned int i)
14 {
15   unsigned int tmp;
16   sv.f2 = i;
17   tmp = sv.f2;
18   if (tmp != 0)
19     abort ();
20 }
21
22 int main()
23 {
24   foo (0xff000000u);
25   return 0;
26 }