re PR c++/8748 (ICE in cp_expr_size at cp/cp-lang.c: 307)
PR c++/8748 * class.c (build_base_path): Take the address before calling save_expr. From-SVN: r61250
This commit is contained in:
parent
970684896d
commit
c226b80339
|
@ -0,0 +1,20 @@
|
|||
// PR c++/8748
|
||||
// We were wrapping the ARRAY_REF in a SAVE_EXPR, causing us to try to make a bitwise
|
||||
// copy of b[0].
|
||||
|
||||
struct A
|
||||
{
|
||||
int i;
|
||||
};
|
||||
|
||||
struct B : A
|
||||
{
|
||||
virtual ~B();
|
||||
};
|
||||
|
||||
struct C
|
||||
{
|
||||
B b[1];
|
||||
};
|
||||
|
||||
void foo() { C().b[0].i; }
|
Loading…
Reference in New Issue