summaryrefslogtreecommitdiff
path: root/support/regression/tests/gcc-torture-execute-bf-sign-1.c
blob: cb2db66b15be674534c196ed54ff85258b4abd17 (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
/*
bf-sign-1.c from the execute part of the gcc torture tests.
*/

#include <testfwk.h>

void
testTortureExecute (void)
{
  struct  {
    signed int s:3;
    unsigned int u:3;
    int i:3;
  } x = {-1, -1, -1};

  if (x.u != 7)
    ASSERT (0);
  if (x.s != - 1)
    ASSERT (0);

  if (x.i != -1 && x.i != 7)
    ASSERT (0);

  return;
}