* stor-layout.c (layout_decl): Unshare size expressions copied
from the type.
Index: stor-layout.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/stor-layout.c,v
retrieving revision 1.218
diff -c -p -d -u -r1.218 stor-layout.c
--- stor-layout.c 9 Dec 2004 10:54:36 -0000 1.218
+++ stor-layout.c 18 Dec 2004 19:16:56 -0000
@@ -325,8 +325,8 @@ layout_decl (tree decl, unsigned int kno
if (DECL_SIZE (decl) == 0)
{
- DECL_SIZE (decl) = TYPE_SIZE (type);
- DECL_SIZE_UNIT (decl) = TYPE_SIZE_UNIT (type);
+ DECL_SIZE (decl) = unsave_expr (TYPE_SIZE (type));
+ DECL_SIZE_UNIT (decl) = unsave_expr (TYPE_SIZE_UNIT (type));
}
else if (DECL_SIZE_UNIT (decl) == 0)
DECL_SIZE_UNIT (decl)