This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/13484] Addition of -fenable-msvc-relaxations option
- From: "gdr at integrable-solutions dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 24 Dec 2003 21:50:38 -0000
- Subject: [Bug c++/13484] Addition of -fenable-msvc-relaxations option
- References: <20031224024633.13484.s_gccbugzilla@nedprod.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From gdr at integrable-solutions dot net 2003-12-24 21:50 -------
Subject: Re: Addition of -fenable-msvc-relaxations option
"s_gccbugzilla at nedprod dot com" <gcc-bugzilla@gcc.gnu.org> writes:
| As I mentioned before, it's done in MSVC using a non const reference
| copy constructor.
But, that is a clear transmutation of the standard C++ semantics; it
is not one which you can play with, will-nilly. But, again, this is
not the first time MSVC is transmuting standard C++ semantics. Not
just because they happen to do it means that GCC should do it. We all
are able to conceived of standard C++ semantics transmutation.
We did experiment in the past along those lines of thoughts where a
cast that produces an rvalue could be treated as a modifiable lvalue.
The net effect was hard-to-find bugs, miscompilations and other
unpleasant maintainance marre. It is not a road I would recommend to
take again.
If you do really want that behaviour, take it to the C++ standards
committee, have them come up with an agreed-upon behaviour and syntax,
then come here again for lobbying its implementation.
-- Gaby
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13484