summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.c-torture/execute/pr40404.c
blob: b2e0ea2755c5525846bc407483825bbc176d47d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
extern void abort (void);

#if (__SIZEOF_INT__ <= 2)
struct S {
  unsigned long ui17 : 17;
} s;
#else
struct S {
  unsigned int ui17 : 17;
} s;
#endif
int main()
{
  s.ui17 = 0x1ffff;
  if (s.ui17 >= 0xfffffffeu)
    abort ();
  return 0;
}