/* PR target/44942 */
|
/* PR target/44942 */
|
|
|
#include <stdarg.h>
|
#include <stdarg.h>
|
|
|
void
|
void
|
test1 (int a, int b, int c, int d, int e, int f, int g, long double h, ...)
|
test1 (int a, int b, int c, int d, int e, int f, int g, long double h, ...)
|
{
|
{
|
int i;
|
int i;
|
va_list ap;
|
va_list ap;
|
|
|
va_start (ap, h);
|
va_start (ap, h);
|
i = va_arg (ap, int);
|
i = va_arg (ap, int);
|
if (i != 1234)
|
if (i != 1234)
|
__builtin_abort ();
|
__builtin_abort ();
|
va_end (ap);
|
va_end (ap);
|
}
|
}
|
|
|
void
|
void
|
test2 (int a, int b, int c, int d, int e, int f, int g, long double h, int i,
|
test2 (int a, int b, int c, int d, int e, int f, int g, long double h, int i,
|
long double j, int k, long double l, int m, long double n, ...)
|
long double j, int k, long double l, int m, long double n, ...)
|
{
|
{
|
int o;
|
int o;
|
va_list ap;
|
va_list ap;
|
|
|
va_start (ap, n);
|
va_start (ap, n);
|
o = va_arg (ap, int);
|
o = va_arg (ap, int);
|
if (o != 1234)
|
if (o != 1234)
|
__builtin_abort ();
|
__builtin_abort ();
|
va_end (ap);
|
va_end (ap);
|
}
|
}
|
|
|
void
|
void
|
test3 (double a, double b, double c, double d, double e, double f,
|
test3 (double a, double b, double c, double d, double e, double f,
|
double g, long double h, ...)
|
double g, long double h, ...)
|
{
|
{
|
double i;
|
double i;
|
va_list ap;
|
va_list ap;
|
|
|
va_start (ap, h);
|
va_start (ap, h);
|
i = va_arg (ap, double);
|
i = va_arg (ap, double);
|
if (i != 1234.0)
|
if (i != 1234.0)
|
__builtin_abort ();
|
__builtin_abort ();
|
va_end (ap);
|
va_end (ap);
|
}
|
}
|
|
|
void
|
void
|
test4 (double a, double b, double c, double d, double e, double f, double g,
|
test4 (double a, double b, double c, double d, double e, double f, double g,
|
long double h, double i, long double j, double k, long double l,
|
long double h, double i, long double j, double k, long double l,
|
double m, long double n, ...)
|
double m, long double n, ...)
|
{
|
{
|
double o;
|
double o;
|
va_list ap;
|
va_list ap;
|
|
|
va_start (ap, n);
|
va_start (ap, n);
|
o = va_arg (ap, double);
|
o = va_arg (ap, double);
|
if (o != 1234.0)
|
if (o != 1234.0)
|
__builtin_abort ();
|
__builtin_abort ();
|
va_end (ap);
|
va_end (ap);
|
}
|
}
|
|
|
int
|
int
|
main ()
|
main ()
|
{
|
{
|
test1 (0, 0, 0, 0, 0, 0, 0, 0.0L, 1234);
|
test1 (0, 0, 0, 0, 0, 0, 0, 0.0L, 1234);
|
test2 (0, 0, 0, 0, 0, 0, 0, 0.0L, 0, 0.0L, 0, 0.0L, 0, 0.0L, 1234);
|
test2 (0, 0, 0, 0, 0, 0, 0, 0.0L, 0, 0.0L, 0, 0.0L, 0, 0.0L, 1234);
|
test3 (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0L, 1234.0);
|
test3 (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0L, 1234.0);
|
test4 (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0L, 0.0, 0.0L,
|
test4 (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0L, 0.0, 0.0L,
|
0.0, 0.0L, 0.0, 0.0L, 1234.0);
|
0.0, 0.0L, 0.0, 0.0L, 1234.0);
|
return 0;
|
return 0;
|
}
|
}
|
|
|