PSL Operator Precedence and Associativity
The precedence and associativity of PSL operators is almost identical to that of C and Perl. The following table lists the PSL operators in descending order of precedence.
Operator | Precedence | Associativity |
---|---|---|
= | lowest | right |
+=, -=, <<=, >>=, ^= |
| right |
*=, /=, %= |
| right |
|=, &= |
| right |
?: (ternary) |
| right |
|| |
| left |
&& |
| left |
| |
| left |
^ |
| left |
& |
| left |
!=, ==, =~, !~ |
| left |
<, <=, >, >= |
| left |
<<, >> |
| left |
+, - (binary) |
| left |
*, /, % |
| left |
. (string concat) |
| left |
-, !, ++, -- |
| right |
() |
| left |
[] | highest | left |
Where to go from here
Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*