re PR middle-end/17525 (ICE in emit_move_insn (non-BLKmode arg))

PR middle-end/17525
        * class.c (build_base_field): Set TYPE_MODE.

From-SVN: r88270
This commit is contained in:
Jason Merrill 2004-09-29 02:23:49 -04:00 committed by Jason Merrill
parent aa24864c23
commit 550f100c57
3 changed files with 23 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2004-09-28 Jason Merrill <jason@redhat.com>
PR middle-end/17525
* class.c (build_base_field): Set TYPE_MODE.
2004-09-28 Roger Sayle <roger@eyesopen.com>
PR driver/17537

View File

@ -3563,6 +3563,7 @@ build_base_field (record_layout_info rli, tree binfo,
DECL_SIZE_UNIT (decl) = CLASSTYPE_SIZE_UNIT (basetype);
DECL_ALIGN (decl) = CLASSTYPE_ALIGN (basetype);
DECL_USER_ALIGN (decl) = CLASSTYPE_USER_ALIGN (basetype);
DECL_MODE (decl) = TYPE_MODE (basetype);
DECL_IGNORED_P (decl) = 1;
DECL_FIELD_IS_BASE (decl) = 1;

View File

@ -0,0 +1,17 @@
// PR middle-end/17525
struct A
{
~A();
int a;
};
struct B : public A
{
virtual ~B();
};
void run (B& b, B& b1)
{
b1 = b;
}