OperationTemplate

Labs

class OperationTemplate

Description

An operator application: the template form of 2 * 3, -x or if c ? a else b.

The operator is its surface string and the operands are in textual order, so op("if", c, a, b) holds (c, a, b). The operand count is fixed by the operator (see SUPPORTED_OPERATORS and op()); + and - admit one operand or two.

Members defined in OperationTemplate (2 members)
Members inherited from ExpressionTemplate (13 members)

__add__

__bool__

Raise: a template is an expression tree, not a truth value.

__mod__

__mul__

__neg__

__pos__

__radd__

__rmod__

__rmul__

__rsub__

__rtruediv__

__sub__

__truediv__

Attributes

operands: tuple[syside.experimental.expressions.ExpressionTemplate, ...] = None
operator: str = None

Used by