Commit 3e527d38 by Richard Henderson Committed by Richard Henderson

stor-layout.c (layout_decl): Unshare size expressions copied from the type.

        * stor-layout.c (layout_decl): Unshare size expressions copied
        from the type.

From-SVN: r92359
parent 29317008
2004-12-18 Richard Henderson <rth@redhat.com> 2004-12-18 Richard Henderson <rth@redhat.com>
* stor-layout.c (layout_decl): Unshare size expressions copied
from the type.
* fold-const.c (multiple_of_p): Handle BIT_AND_EXPR when * fold-const.c (multiple_of_p): Handle BIT_AND_EXPR when
BOTTOM is a power of two. BOTTOM is a power of two.
......
...@@ -325,8 +325,8 @@ layout_decl (tree decl, unsigned int known_align) ...@@ -325,8 +325,8 @@ layout_decl (tree decl, unsigned int known_align)
if (DECL_SIZE (decl) == 0) if (DECL_SIZE (decl) == 0)
{ {
DECL_SIZE (decl) = TYPE_SIZE (type); DECL_SIZE (decl) = unsave_expr (TYPE_SIZE (type));
DECL_SIZE_UNIT (decl) = TYPE_SIZE_UNIT (type); DECL_SIZE_UNIT (decl) = unsave_expr (TYPE_SIZE_UNIT (type));
} }
else if (DECL_SIZE_UNIT (decl) == 0) else if (DECL_SIZE_UNIT (decl) == 0)
DECL_SIZE_UNIT (decl) DECL_SIZE_UNIT (decl)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment