6.5.3.2 Address and indirection operators

Previous Table of Contents

1078 The operand of the unary & operator shall be either a function designator, the result of a [] or unary * operator, or an lvalue that designates an object that is not a bit-field and is not declared with the register storage-class specifier.

1079 The operand of the unary * operator shall have pointer type.

1080 The unary & operator yields the address of its operand.

1081 If the operand has type “type”, the result has type “pointer to type”.

1082 If the operand is the result of a unary * operator, neither that operator nor the & operator is evaluated and the result is as if both were omitted, except that the constraints on the operators still apply and the result is not an lvalue.

1083 Similarly, if the operand is the result of a [] operator, neither the & operator nor the unary * that is implied by the [] is evaluated and the result is as if the & operator were removed and the [] operator were changed to a + operator.

1084 Otherwise, the result is a pointer to the object or function designated by its operand.

1085 The unary * operator denotes indirection.

1086 If the operand points to a function, the result is a function designator;

1087 if it points to an object, the result is an lvalue designating the object.

1088 If the operand has type “pointer to type”, the result has type “type”.

1089 If an invalid value has been assigned to the pointer, the behavior of the unary * operator is undefined.84)

1090 Forward references: storage-class specifiers (6.7.1), structure and union specifiers (6.7.2.1).

Next

Created at: 2005-06-29 02:18:59 The text from WG14/N1124 is copyright © ISO