This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/63526] O1 O2 O3 optimization and inline template constructor - uninitialized member
- From: "redi at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 13 Oct 2014 23:00:14 +0000
- Subject: [Bug c++/63526] O1 O2 O3 optimization and inline template constructor - uninitialized member
- Auto-submitted: auto-generated
- References: <bug-63526-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63526
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution|--- |INVALID
--- Comment #4 from Jonathan Wakely <redi at gcc dot gnu.org> ---
The text you quote describes how f is initialized, it does not apply to f._foo.
You provided a default constructor, so the compiler uses that and assumes that
you wrote it correctly to do what you want.
If you want Foo's members to be initialized then fix your constructor.