public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "redi at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/25811] No failure creating a POD containing a const member, using new without a new-initializer. Date: Wed, 31 Mar 2010 08:55:00 -0000 [thread overview] Message-ID: <20100331085528.24547.qmail@sourceware.org> (raw) In-Reply-To: <bug-25811-12027@http.gcc.gnu.org/bugzilla/> ------- Comment #8 from redi at gcc dot gnu dot org 2010-03-31 08:55 ------- (N.B. your email to gcc-patches gives the wrong PR number in the subject.) This reject the following valid program: struct X { X() : c(0), r(c) {} const int c; int const& r; }; int main() { new X; } If there is a default constructor it will be called, and so the members will not be uninitialized. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25811
next prev parent reply other threads:[~2010-03-31 8:55 UTC|newest] Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top 2006-01-16 20:00 [Bug c++/25811] New: " fabien dot chene at laposte dot net 2006-01-16 20:06 ` [Bug c++/25811] " pinskia at gcc dot gnu dot org 2010-03-30 8:22 ` fabien dot chene at gmail dot com 2010-03-30 9:16 ` redi at gcc dot gnu dot org 2010-03-30 10:07 ` fabien dot chene at gmail dot com 2010-03-30 10:10 ` fabien dot chene at gmail dot com 2010-03-30 11:19 ` redi at gcc dot gnu dot org 2010-03-31 7:07 ` fabien dot chene at gmail dot com 2010-03-31 8:55 ` redi at gcc dot gnu dot org [this message] 2010-03-31 12:21 ` fabien dot chene at gmail dot com 2010-03-31 12:34 ` redi at gcc dot gnu dot org 2010-03-31 13:46 ` fabien dot chene at gmail dot com 2010-03-31 13:53 ` redi at gcc dot gnu dot org 2010-04-12 19:58 ` jason at gcc dot gnu dot org [not found] <bug-25811-4@http.gcc.gnu.org/bugzilla/> 2012-05-24 22:46 ` paolo.carlini at oracle dot com
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20100331085528.24547.qmail@sourceware.org \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).