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

#include <testfwk.h>

#ifdef __SDCC
#pragma std_c99
#endif

const char *
f (const char *p)
{
  short x = *p++ << 16;
  return p;
}

void
testTortureExecute (void)
{
  const char *p = "";
  if (f (p) != p + 1)
    ASSERT(0);
  return;
}