An expression has many characteristics that determine what sort
of operations can be performed.
-
Scalar: A scalar type is a simple-type value,
ranging from 1 to 8 bytes in size, that can
be added, subtracted, multiplied, etc.
-
Structured: A structure type is a reference to a memory
location (but not strictly a pointer to this memory location)
that contains a non-simple type data structure.
A structure’s size can be any positive number of bytes.
-
Pointer: A pointer type is a 16-byte portion of data
that refers to existing data.
-
Variable Name: The name of a global variable, member
variable, parameter variable, or local variable.
In many cases, it is not possible to distinguish any additional characteristics
about a variable until the expression is further evaluated against other
expressions. For example, the “sizeof” operator or
structure member dereference
operator respect the current variable scope when evaluating the expression.
-
Variable Type: A simple type name (void,
char, short, long, longlong,
float, or double) or the name of a data
structure. Variable type is only used in special cases, such
as “sizeof,” “new,” “newchild,”
and in typecasts.
-
Integer: The scalar types char, short,
long, and longlong
are integer types.
-
Floating Point: The scalar types float and
double
are floating-point types.
-
Pointer-To-Void: A pointer with no certainty as to the pointed-to
type.
-
Pointer-To-Scalar: A pointer that points to a scalar type.
-
Pointer-To-Structure: A pointer that points to a structured
type.
-
Signed/Unsigned Integer: An integer scalar expression can be
either signed or unsigned. In some
contexts, such as addition, an integer is assumed to be either
signed or unsigned regardless of the sign
associated with the expression. In other contexts, such as multiplication,
the sign of the expression
determines how the expression must be evaluated.
-
Constant Value: A constant value is a scalar, structure, or
pointer value that represents transitionary data that can be
read from, but cannot be written to.
-
L-Value: An L-value is a scalar, structure, or pointer value
that can be both read from and written to (that is, it can
serve as a valid left-hand-side value of an assignment
operation).
See also: [Expression
characteristics] [Identifier interpretations]
[Built-in functions] [Special
load considerations]
[Additional rules for expressions] [Final
expression type result] [L-value status gain and
loss]
[Overly complex expressions] [Limitations
on pointer usage] [Structure member
dereference: bit scan blocks]
|