URL
https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 149 |
Rev 154 |
extern void abort (void);
|
extern void abort (void);
|
extern void exit (int);
|
extern void exit (int);
|
|
|
struct B
|
struct B
|
{
|
{
|
int x;
|
int x;
|
int y;
|
int y;
|
};
|
};
|
|
|
struct A
|
struct A
|
{
|
{
|
int z;
|
int z;
|
struct B b;
|
struct B b;
|
};
|
};
|
|
|
struct A
|
struct A
|
f ()
|
f ()
|
{
|
{
|
struct B b = { 0, 1 };
|
struct B b = { 0, 1 };
|
struct A a = { 2, b };
|
struct A a = { 2, b };
|
return a;
|
return a;
|
}
|
}
|
|
|
int
|
int
|
main (void)
|
main (void)
|
{
|
{
|
struct A a = f ();
|
struct A a = f ();
|
if (a.z != 2 || a.b.x != 0 || a.b.y != 1)
|
if (a.z != 2 || a.b.x != 0 || a.b.y != 1)
|
abort ();
|
abort ();
|
exit (0);
|
exit (0);
|
}
|
}
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.