The original question is related to overloading operator= and I like to share my findings as it was nontrivial for me to find them.
I cannot imagine reasonable example to use (a=b) as lvalue.
With the help of IRC and google I’ve found the next article:
http://msdn.microsoft.com/en-us/magazine/cc301415.aspx
it provides two examples.
(a=b)=c
f(T& );
f(a=b)
but both a bit not good, and I believe that it is bad practice.
The second one give me the same feeling.
Could you provide more good examples why it should be non constant?
One good reason is that one of the requirements in the standard for a class
Xto be useable in the standard containers is that the expressiona = bmust have typeX&(whereais an lvalue of typeXandbis an rvalue of typeX).