OSDN Git Service

Fix PR 17408 and PR 17409.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gcc.c-torture / execute / 961213-1.c
1 int
2 g (unsigned long long int *v, int n, unsigned int a[], int b)
3 {
4   int cnt;
5   *v = 0;
6   for (cnt = 0; cnt < n; ++cnt)
7     *v = *v * b + a[cnt];
8   return n;
9 }
10
11 main ()
12 {
13   int res;
14   unsigned int ar[] = { 10, 11, 12, 13, 14 };
15   unsigned long long int v;
16
17   res = g (&v, sizeof(ar)/sizeof(ar[0]), ar, 16);
18   if (v != 0xabcdeUL)
19     abort ();
20
21   exit (0);
22 }