This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/12591] New: gcc accepts invalid code


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();


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]