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] 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



------- Additional Comments From falk at debian dot org  2003-10-13 11:21 -------
Compaq's compiler says this when enabling strict ANSI mode:

cxx: Warning: test.cc, line 8: "foo::foo(const foo &)", required for copy that
          was eliminated, is inaccessible
const foo &bar = foo();
-----------------^

So it is not invalid because the copy was eliminated, which to do the compiler
is allowed.

Maybe we could modify this to a low priority warning request for something
similar.


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