From: Richard Henderson Date: Mon, 7 Oct 2002 09:54:27 +0000 (-0700) Subject: * decl2.c: Complete reversion of c++/7754. X-Git-Tag: releases/gcc-3.2.1~194 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c24b0c5d9505341b9a0ffd3796bfcb358d259930;p=thirdparty%2Fgcc.git * decl2.c: Complete reversion of c++/7754. From-SVN: r57896 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index b8009df74958..f4738ece154d 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2002-10-07 Richard Henderson + + * decl2.c: Complete reversion of c++/7754. + 2002-10-06 Roger Sayle PR optimization/6627 diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c index 43349631b4de..0eb47994b20a 100644 --- a/gcc/cp/decl2.c +++ b/gcc/cp/decl2.c @@ -1975,31 +1975,26 @@ finish_anon_union (anon_union_decl) return; } - if (!processing_template_decl) - { - main_decl - = build_anon_union_vars (anon_union_decl, - &DECL_ANON_UNION_ELEMS (anon_union_decl), - static_p, external_p); - - if (main_decl == NULL_TREE) - { - warning ("anonymous aggregate with no members"); - return; - } + main_decl = build_anon_union_vars (anon_union_decl, + &DECL_ANON_UNION_ELEMS (anon_union_decl), + static_p, external_p); - if (static_p) - { - make_decl_rtl (main_decl, 0); - COPY_DECL_RTL (main_decl, anon_union_decl); - expand_anon_union_decl (anon_union_decl, - NULL_TREE, - DECL_ANON_UNION_ELEMS (anon_union_decl)); - return; - } + if (main_decl == NULL_TREE) + { + warning ("anonymous aggregate with no members"); + return; } - add_decl_stmt (anon_union_decl); + if (static_p) + { + make_decl_rtl (main_decl, 0); + COPY_DECL_RTL (main_decl, anon_union_decl); + expand_anon_union_decl (anon_union_decl, + NULL_TREE, + DECL_ANON_UNION_ELEMS (anon_union_decl)); + } + else + add_decl_stmt (anon_union_decl); } /* Finish processing a builtin type TYPE. It's name is NAME,