Appendix A: System Routines — Logic
743
TI
-
89 / TI
-
92 Plus Developer Guide
Not for Distribution
Beta Version January 26, 2001
push_when
Declaration:
void
push_when
(EStackIndex
i
)
Category(ies):
Logic
Description:
If the Boolean expression or all of its elements internally simplify to TRUE,
then the internally-simplified equivalent of the “then” expression is pushed
onto the estack.
Otherwise if the Boolean expression or any of its elements internally
simplify to FALSE and there is an Else expression, then its
internally-simplified equivalent is pushed.
Otherwise if there is an unknown expression, then its internally-simplified
equivalent is pushed.
Otherwise the tail indexed by
i
is pushed, then a WHEN_TAG is pushed.
Inputs:
i
— Indexes a tail of 2, 3 or 4 successive expressions on top of an
END_TAG: a Boolean expression or an aggregate thereof on top of
a Then expression, optionally on top of an Else expression,
optionally on top of an Unknown expression.
Outputs:
None
Assumptions:
None
Side Effects:
None
Availability:
On AMS 2.02 and higher.
TI
-
89 / TI
-
92 Plus
Differences:
None
See Also: push_sign
Example:
push_quantum (END_TAG);
push0 ();
push1 ();
push_quantum (TRUE_TAG);
push_when (top_estack); /* Pushes a copy of the above-pushed one. */