关于lvalue and rvalue

lvalue :An object is a region of storage that can be examined and stored into.An lvalue does not necessarily permit modification of the object it designates: eg

An array type

An incomplete type

A const-qualified type

An object is a structure or union type and one of its members has a const-qualified type

rvalue:

The term rvalue refers to a data value that is stored at some address in memory. An rvalue is an expression that cannot have a value assigned to it.

lvalue 更代表的一个区域,虽然你不一定可以更改这个区域的内容,但你更清楚在语言层面更代表一个区域。

rvalue 更代表一个值,你更清楚在语言层面更代表一个数值

你可能感兴趣的:(关于lvalue and rvalue)