2 // GROUPS passed miscellaneous
3 //The program listed below produces the following error during compilation:
5 // bug17.cc: In method `class Y& Y::operator = (const class Y&)':
6 // bug17.cc:18: invalid use of non-lvalue array
10 X& operator=(const X&) { return *this; }
21 const S& f() const { return s; }
23 Y& operator=(const Y& _Y) {
24 s = _Y.s; // this line compiles
25 s = _Y.f(); // this line does not compile