URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 297 |
Rev 338 |
struct A
|
struct A
|
{
|
{
|
int one;
|
int one;
|
int two;
|
int two;
|
int three;
|
int three;
|
int four;
|
int four;
|
int five;
|
int five;
|
int six;
|
int six;
|
};
|
};
|
|
|
static int test (void)
|
static int test (void)
|
{
|
{
|
int base;
|
int base;
|
|
|
struct A Foo (void)
|
struct A Foo (void)
|
{
|
{
|
struct A a;
|
struct A a;
|
|
|
a.one = base + 1;
|
a.one = base + 1;
|
a.two = base + 2;
|
a.two = base + 2;
|
a.three = base + 3;
|
a.three = base + 3;
|
a.four = base + 4;
|
a.four = base + 4;
|
a.five = base + 5;
|
a.five = base + 5;
|
a.six = base + 6;
|
a.six = base + 6;
|
|
|
return a;
|
return a;
|
}
|
}
|
|
|
base = 10;
|
base = 10;
|
struct A a = Foo ();
|
struct A a = Foo ();
|
|
|
return (a.one == 11
|
return (a.one == 11
|
&& a.two == 12
|
&& a.two == 12
|
&& a.three == 13
|
&& a.three == 13
|
&& a.four == 14
|
&& a.four == 14
|
&& a.five == 15
|
&& a.five == 15
|
&& a.six == 16);
|
&& a.six == 16);
|
}
|
}
|
|
|
int main (void)
|
int main (void)
|
{
|
{
|
return !test ();
|
return !test ();
|
}
|
}
|
|
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.