This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/12591] New: gcc accepts invalid code
- From: "hg211 at ural2 dot hszk dot bme dot hu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Oct 2003 20:45:20 -0000
- Subject: [Bug c++/12591] New: gcc accepts invalid code
- 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=12591
Summary: gcc accepts invalid code
Product: gcc
Version: 3.4
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: hg211 at ural2 dot hszk dot bme dot hu
CC: gcc-bugs at gcc dot gnu dot org
gcc version 3.3.2 20030908 (Debian prerelease)
and
gcc version 3.4 20031005 (experimental)
accept this invalid code (it's invalid because the copy-constructor is
inaccessible):
class foo {
private:
foo(const foo &);
public:
foo();
};
const foo &bar = foo();