This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/51365] cannot use final empty class in std::tuple
- From: "marc.glisse at normalesup dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 11 Dec 2011 12:12:29 +0000
- Subject: [Bug libstdc++/51365] cannot use final empty class in std::tuple
- Auto-submitted: auto-generated
- References: <bug-51365-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51365
Marc Glisse <marc.glisse at normalesup dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |marc.glisse at normalesup
| |dot org
--- Comment #9 from Marc Glisse <marc.glisse at normalesup dot org> 2011-12-11 12:12:29 UTC ---
Hello,
the recent discussion "Structure alignment changes when a constructor or
destructor is added" on gcc-help made me wonder whether it would make sense to
not only derive for empty classes, but actually derive by default and use
members only when necessary (builtin types, final classes). The advantage would
be that derivation allows for a slightly more compact representation in some
cases with the g++ ABI. I really haven't thought much about the consequences.
Sorry for hijacking this bug with this wild idea, but in case it makes sense it
might change slightly the way you want to fix it.