This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/18975] Copying objects with mutable non-static data members
- From: "wolfgang dot roehrl at de dot gi-de dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 14 Dec 2004 14:19:48 -0000
- Subject: [Bug c++/18975] Copying objects with mutable non-static data members
- References: <20041214071926.18975.wolfgang.roehrl@de.gi-de.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From wolfgang dot roehrl at de dot gi-de dot com 2004-12-14 14:19 -------
Subject: Antwort: Copying objects with mutable non-static data
members
Hi all,
I'm responding to Comments From nathan at gcc dot gnu dot org 2004-12-14
13:57 (bug 18975):
I just tried the code fragment with the Comeau online compiler. The
compiler does generate implicitly the copy contructor but it refuses to
generate
implicitly the copy assignment operator. That means the Comeau compiler
translates the mentioned code fragment if line 20 is un-commented, i.e. if
we have an user-defined copy assignment operator. But it is not necessary
to un-comment line 19, i.e. we don't need an user-defined copy constructor.
Regards,
W. Roehrl
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18975