This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/12567] New: g++ fails to recognize ill-formed-ness of initilaizers
- From: "debian-gcc at lists dot debian dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 10 Oct 2003 08:55:12 -0000
- Subject: [Bug c++/12567] New: g++ fails to recognize ill-formed-ness of initilaizers
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12567
Summary: g++ fails to recognize ill-formed-ness of initilaizers
Product: gcc
Version: 3.3.2
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: debian-gcc at lists dot debian dot org
CC: gcc-bugs at gcc dot gnu dot org
[forwarded from http://bugs.debian.org/195468]
g++ fails to recognize the ill-formed-ness of at least the following cases,
happily succeeds compiling them...:
struct foo {
virtual void f(void);
};
struct bar {
bar (); // user defined default constructor
};
struct doo {
bar m_bar; // non-POD member w/ u.d.d.c
};
struct zoo: public bar { }; // inherited u.d.d.c
const foo a_foo; // ill-formed - foo has no user-declared def-cons
const bar a_bar; // ok
const doo a_doo; // ill-formed - doo has no user-declared def-cons
const zoo a_zoo; // ill-formed? not sure about this one...