Expressions
Operations (Binary and Unary)
Higher precedences are executed first.
Supported Binary Operations (and Precedence):
| Operation | Symbol | Precedence |
|---|---|---|
| Not | ! | 130 |
| Modulus | % | 120 |
| Multiply | * | 110 |
| Divide | / | 110 |
| Add | + | 100 |
| Subtract | - | 100 |
| Left Shift | << | 90 |
| Right Shift | >> | 90 |
| Less or Equal | <= | 80 |
| Greater or Equal | >= | 80 |
| Less Than | < | 70 |
| Greater Than | > | 70 |
| Equal | == | 60 |
| Not Equal | != | 60 |
| Bitwise And | & | 50 |
| Bitwise Xor | ^ | 40 |
| Bitwise Or | ||
| Logical And | && | 20 |
| Logical Or | || | 10 |
Supported Unary Operations:
| Operation | Symbol |
|---|---|
| Negative | -<num> |
| Not | !<bool> |
| Cast | <type>’<expr> |