TAL Programmer's Guide
Conditional Expressions
Using Expressions
5–22 096254 Tandem Computers Incorporated
Boolean Operators You use Boolean operators—NOT, OR, and AND—to set the state of a single value or
the relationship between two values. Table 5-16 describes the Boolean operators, the
operand types you can use with them, and the results that such operators yield.
Table 5-16. Boolean Operators and Result Yielded
Operator Operation Operand Type Result Example
NOT Boolean negation; tests
condition for false state
STRING, INT, or
UNSIGNED(1–16)
True/False NOT a
OR Boolean disjunction; produces
true state if either adjacent
condition is true
STRING, INT, or
UNSIGNED(1–16)
True/False a OR b
AND Boolean conjunction; produces
true state if both adjacent
conditions are true
STRING, INT, or
UNSIGNED(1–16)
True/False a AND b
Evaluation of Boolean Operations
Conditions connected by the OR operator are evaluated from left to right only until a
true condition occurs.
Conditions connected by the AND operator are evaluated from left to right until a
false condition occurs. The next condition is evaluated only if the preceding condition
is true. In the following example, function F will not be called because A <> 0 is false:
a := 0;
IF a <> 0 AND f(x) THEN ... ;
Effect on Hardware Indicators
Boolean operators set the condition code indicator, as described in “Testing Hardware
Indicators” later in this section.