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

#include <testfwk.h>

#ifdef __SDCC
#pragma std_c99
#endif

#include <limits.h>

int
sub ()
{
  int dummy = 0, a = 16;

  if (a / INT_MAX / 16 == 0)
    return 0;
  else
    return a / INT_MAX / 16;
}

void
testTortureExecute (void)
{
  if (sub () != 0)
    ASSERT (0);

  return;
}