URL
https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk
Subversion Repositories openrisc_2011-10-31
[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [g++.old-deja/] [g++.jason/] [member.C] - Rev 154
Compare with Previous | Blame | View Log
// { dg-do assemble }
// GROUPS passed member-pointers error-reporting
struct Y
{
struct X
{
int A;
int Y::X::* foo () { undef1(1); return &Y::X::A; }// { dg-error "" } foo().*
int bar () { return A; }
};
};
int Y::X::* foo ()
{
undef2(1);// { dg-error "" } foo().*
return &Y::X::A;
}
int Y::X::* (* foo2 ())()
{
undef3(1);// { dg-error "" } foo().*
return foo;
}
int (Y::X::* bar2 ()) ()
{
undef4(1);// { dg-error "" } foo\(\).*
return Y::X::bar;// { dg-error "" } foo\(\).*
}
int Y::X::* (Y::X::* foo3 ())()
{
undef5(1);// { dg-error "" } foo().*
return Y::X::foo;// { dg-error "" } foo().*
}