The following operators are used in expressions in TAMEScript to calculate values.
They also have a set precedence outlined in a table at the end of this page.
Some operators requires only one operand (unary), and others require two (binary), and one is
used as an if-else branch.
Operator Precedence
Operators have a built-in precedence when used without parenthesis to affect order of operations. From highest to lowest,
this is the precedence for all of TAME's operators (same line has equal precedence).
( ) |
(unary operators) - ! + |
** |
* / % |
+ - |
< <= > >= |
== != === !== |
& |
^ |
| |
&& |
|| |
(ternary operator) ? : |
It is also worth noting that the power operator (**) is right-associative - the right side is evaluated first,
if more power operators are used successively (e.g. 6 ** 3 ** 2: 3 ** 2 is evaluated first).