This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/15938] ICE with anonymous unions
- From: "giovannibajo at libero dot it" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 21 Jul 2005 15:32:11 -0000
- Subject: [Bug c++/15938] ICE with anonymous unions
- References: <20040611122359.15938.reichelt@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From giovannibajo at libero dot it 2005-07-21 15:32 -------
It might indeed be obsolete code: I don't think you can currently create an
union (or a record) with only unnamed fields. If you want to purse this
further, you could regtest changing this:
if (!field)
{
error ("union %qT with no named members cannot be initialized",
type);
ce->value = error_mark_node;
}
with "gcc_assert (field);". Which will probably succeed, as there are no
occurrences of this error message in my last g++.log.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15938