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++/15218] [DR 421] rvalue.field is not an lvalue



------- Comment #3 from dibeas at ieee dot org  2010-02-08 12:11 -------
Also related: dereferencing a data member pointer with an lvalue incorrectly
yields an lvalue:

struct X { int x; };
X f();
void g() {
   int X::*ptr = &X::x;
   f().*ptr = 5;       // should not compile!
}


-- 

dibeas at ieee dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dibeas at ieee dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15218


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