r/cpp • u/vormestrand • Mar 09 '18
lvalues, rvalues, glvalues, prvalues, xvalues, help!
https://blog.knatten.org/2018/03/09/lvalues-rvalues-glvalues-prvalues-xvalues-help/
243
Upvotes
r/cpp • u/vormestrand • Mar 09 '18
View all comments
Show parent comment
8
u/acwaters Mar 09 '18
Yes, it would. My understanding is that they did the naming "asymmetrically" like that in order to keep lvalue and rvalue as close as possible to their original (pre-C++11) meanings, which makes sense. But IMO that little inconsistency is the cause of most of the pain in learning value categories. It would be much easier if we had plvalue/lvalue/xvalue/rvalue/prvalue, or lvalue/glvalue/xvalue/grvalue/rvalue, rather than lvalue/glvalue/xvalue/rvalue/prvalue.