### 7.2 Lvalues ¶

An expression that identifies a memory space that holds a value is called an lvalue, because it is a location that can hold a value.

The standard kinds of lvalues are:

- A variable.
- A pointer-dereference expression (see Dereferencing Pointers) using unary ‘`*`’, if its type is not a function type.
- A structure field reference (see Structures) using ‘`.`’, if the structure value is an lvalue.
- A structure field reference using ‘`->`’. This is always an lvalue since ‘`->`’ implies pointer dereference.
- A union alternative reference (see Unions), on the same conditions as for structure fields.
- An array-element reference using ‘`[…]`’, if the array is an lvalue.
- A string constant (see String Constants).
- An array constructor (see Constructing Array Values).
- A structure or union constructor (see Structure Constructors).

If an expression’s outermost operation is any other operator, that expression is not an lvalue. Thus, the variable `x` is an lvalue, but `x + 0` is not, even though these two expressions compute the same value (assuming `x` is a number).

It is rare that a structure value or an array value is not an lvalue, but that does happen—for instance, the result of a function call or a conditional operator can have a structure or array type, but is never an lvalue.

If an array is an lvalue, using the array in an expression still converts it automatically to a pointer to the zeroth element. The result of this conversion is not an lvalue. Thus, if the variable `a` is an array, you can’t use `a` by itself as the left operand of an assignment. But you can assign to an element of `a`, such as `a[0]`. That is an lvalue since `a` is an lvalue.