Promela |
operator precedence rules |
Arithmetic and Boolean Operator Precedence Rules, High to Low:
Operators | Associativity | Comment |
() [] . | left to right | parentheses, array brackets (highest precedence) |
! ~ ++ -- | right to left | negation, complement, increment, decrement |
* / % | left to right | multiplication, division, modulo |
+ - | left to right | addition, subtraction |
<< >> | left to right | left and right shift |
< <= > >= | left to right | relational operators |
== != | left to right | equal, unequal |
& | left to right | bitwise and |
^ | left to right | bitwise exclusive or |
| | left to right | bitwise or |
&& | left to right | logical and |
|| | left to right | logical or |
-> : | right to left | conditional expression operators |
= | right to left | assignment (lowest precedence) |
Spin Online References Promela Manual Index Promela Grammar Spin HomePage |
(Page added: 6 April 2011) |