* gcc.c-torture/execute/20021015-1.c: New test.
From-SVN: r58159
This commit is contained in:
parent
2d34c58790
commit
23a64177fb
@ -1,3 +1,7 @@
|
||||
2002-10-15 Ulrich Weigand <uweigand@de.ibm.com>
|
||||
|
||||
* gcc.c-torture/execute/20021015-1.c: New test.
|
||||
|
||||
Tue Oct 15 14:22:41 2002 J"orn Rennecke <joern.rennecke@superh.com>
|
||||
|
||||
* gcc.dg/weak/typeof-2.c: For SH targets, return before baz3 test.
|
||||
|
30
gcc/testsuite/gcc.c-torture/execute/20021015-1.c
Normal file
30
gcc/testsuite/gcc.c-torture/execute/20021015-1.c
Normal file
@ -0,0 +1,30 @@
|
||||
/* PR opt/7409. */
|
||||
|
||||
extern void abort (void);
|
||||
|
||||
char g_list[] = { '1' };
|
||||
|
||||
void g (void *p, char *list, int length, char **elementPtr, char **nextPtr)
|
||||
{
|
||||
if (*nextPtr != g_list)
|
||||
abort ();
|
||||
|
||||
**nextPtr = 0;
|
||||
}
|
||||
|
||||
int main (void)
|
||||
{
|
||||
char *list = g_list;
|
||||
char *element;
|
||||
int i, length = 100;
|
||||
|
||||
for (i = 0; *list != 0; i++)
|
||||
{
|
||||
char *prevList = list;
|
||||
g (0, list, length, &element, &list);
|
||||
length -= (list - prevList);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user