summaryrefslogtreecommitdiff
path: root/support/regression/tests/gcc-torture-execute-20040331-1.c
blob: d98cb197bf7542fd981ad44df68f90d377be016f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/*
   20040331-1.c from the execute part of the gcc torture suite.
 */

#include <testfwk.h>

#ifdef __SDCC
#pragma std_c99
#endif

#include <limits.h>

/* PR c++/14755 */

void
testTortureExecute (void)
{
#if INT_MAX >= 2147483647
  struct { int count: 31; } s = { 0 };
  while (s.count--)
    ASSERT (0);
#elif INT_MAX >= 32767
  struct { int count: 15; } s = { 0 };
  while (s.count--)
    ASSERT (0);
#else
  /* Don't bother because __INT_MAX__ is too small.  */
#endif
  return;
}