This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/38870] G++ allows modification of data members for a non lvalue object
- From: "stefan dot constantin at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 Jan 2009 12:07:37 -0000
- Subject: [Bug c++/38870] G++ allows modification of data members for a non lvalue object
- References: <bug-38870-17193@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from stefan dot constantin at gmail dot com 2009-01-16 12:07 -------
Sorry for not mentioning this earlier,
the sample program provide compiles without error or warning with
g++ -Wall.
I expected the compiler to error on the line "tester().i = 10;" because such a
construct requires an lvalue.
Thanks
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38870