20020307-2.c (main): Pass a variable sized structure.

* gcc.c-torture/execute/20020307-2.c (main): Pass a variable sized
        structure.

From-SVN: r51376
This commit is contained in:
Richard Henderson 2002-03-26 00:53:14 -08:00 committed by Richard Henderson
parent 1447dc6909
commit 43f2b30807
2 changed files with 8 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2002-03-26 Richard Henderson <rth@redhat.com>
* gcc.c-torture/execute/20020307-2.c (main): Pass a variable sized
structure.
2002-03-25 Richard Henderson <rth@redhat.com>
* gcc.dg/20001013-1.c: Add -mcpu=ultrasparc. Only run on

View File

@ -38,7 +38,8 @@ void foo (int size, ...)
int main (void)
{
struct { char a[5]; } x, y;
int z = 5;
struct { char a[z]; } x, y;
x.a[0] = '0';
x.a[1] = '1';
@ -50,6 +51,6 @@ int main (void)
y.a[2] = '7';
y.a[3] = '8';
y.a[4] = '9';
foo (5, x, y);
foo (z, x, y);
exit (0);
}