> Besides, as far as I understand it (but I may be wrong on that, I haven't investigated very far), it seems to me that it is not really a issue of precedence between the operators, but a simpler question of left to right
Well, you are not "knowing" you are "guessing"...
... and that's not a good base for designing code.
What's worse, I also guessed that and and or have the same precedence ...
... but now take a look what B::Deparse says:
DB<102> dp $a and $b or $c { $c unless $a and $b; } DB<103> dp $a or $b and $c { $b and $c unless $a; }
too many surprises for my taste. =)
from perlop
Operator Precedence and Associativity ... nonassoc list operators (rightward) right not left and left or xor
Cheers Rolf
( addicted to the Perl Programming Language)
In reply to Re^4: Looking for discussions of "block after or" syntax error
by LanX
in thread Looking for discussions of "block after or" syntax error
by wsanders
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |