http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50285
Jonathan Wakely <redi at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |WAITING Last reconfirmed| |2011-09-04 Ever Confirmed|0 |1 --- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-09-04 18:06:54 UTC --- An error message is not a bug, please follow the bug reporting instructions and provide source code for a testcase demonstrating your problem: http://gcc.gnu.org/bugs/ The message clearly isn't about converting a type to itself, it's about converting a type to a non-const lvalue reference to that type (X is not the same as X&) I assume it means you're trying to pass an rvalue (e.g. a temporary) to a function that requires an lvalue e.g. this produces a similar error struct X { X& operator=(X&); }; X f(); void g() { X x; x = f(); }