On how to recognize Rvalue or Lvalue reference and if-it-has-a-name rule
I was reading Thomas Becker's article on rvalue reference and their use. In there he defines what he calls if-it-has-a-name rule: Things that are declared as rvalue reference can be lvalues or rvalues. The distinguishing criterion is: if it has a name, then it is an lvalue. Otherwise, it is an rvalue. This sounds very reasonable to me. It also clearly identifies the rvalueness of an rvalue reference. My questions are: Do you agree with this rule? If not, can you give an example where this rule can be violated? If there are no violations of this rule. Can we use this rule to define rvalueness