An expression is a computational rule for producing a data item. An expression can be a single operand or a combination of
operators and operands. Operators are either prefix or infix operators. Prefix operators immediately precede an operand.
Infix operators operate upon a left and right operand to produce a value. The association of operands to an operator is determined by the
precedence of operators. Operands are associated with the operator of higher precedence.
Parentheses can be used to modify the association (see Section 5.3).
Operator symbol 1 xx is a prefix operator. Valid prefix operator symbols are +, -, and NOT.
Operator symbol 2 is an infix operator. Valid infix operator symbols are **, *, /, MOD, DIV, &, +, -, =, /=, <. <=,
>, >=, IN, AND, OR, and XOR.
The operands of prefix and infix operators are determined based on the built-in precedence of operators given below:
Within a precedence level, associativity is left to right.
Arithmetic operators (infix +, -, *, /, **, modulo (MOD), integer division (DIV), and prefix +, -) take operands of
arithmetic types (INT, FLOAT, and FIXED) and return arithmetic values.
A concatenation operator (infix &) takes string and enumeration operands and produces a string, or takes
one-dimensional array operands and produces a one-dimensional array.
Relational operators (infix *, not equal (/=), <, <=, >, >=, set membership (IN)) take arithmetic, boolean,
enumeration, string, and notoperands and return a boolean. For boolean operands, only - and /= are defined. For arithmetic operands, the relational operators
define a numerical ordering.
For enumeration and string operands, the relational operators define a collating sequence.
For set operands, the relational operators define a subset relationship.
Logical operators (infix AND, OR, XOR, and prefix NOT) take boolean operands and produce a boolean, or take set operands and produce a set.
For boolean operands, the logical operators define and, or, exclusive or, and complement.
For set operands, the logical operators define set intersection, union, symmetric difference, and complement.
A type or subtype comparison is one which is used to compare types or subtypes and returns a boolean
value. This form of expression is described in Section 4.5.1 and 4.5.2.
It is possible to overload the built-in definitions of operators to allow
user-defined operators (see Section 13.2).