URL
https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk
Subversion Repositories openrisc_2011-10-31
[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc2/] [gcc/] [testsuite/] [g++.old-deja/] [g++.other/] [crash22.C] - Rev 384
Compare with Previous | Blame | View Log
// { dg-do link }
// { dg-options "-O2" }
class foo
{
};
typedef void *voidp;
class vect : public foo
{
public:
voidp& a();
int b();
};
class bar
{
public:
bar *c(bool (*f)(bar *node), voidp g)
{
int i=0;
bool j;
while (i < d.b()){
j = (f == __null) || f((bar*)d.a());
if (j)
((bar*)d.a())->c(f, g);
i++;
}
return this;
}
public:
vect d;
bar *e(foo *k);
};
bar *bar::e(foo *k)
{
return c(__null, k);
}
voidp &vect::a()
{
static voidp x;
return x;
}
int vect::b()
{
static int x;
return x;
}
int main()
{
return 0;
}