Based on
perlop , the terany operator (?:) is just one precidence level above the "operate and set" operators .=, +=, etc.
Thus, perl is seeing:
print ($x ? $x.="hello" : $x.="Bye");
as
print ( ( $x ? $x.="hello" : $x ) .="Bye");
and not as
print ( $x ? $x.="hello" : ( $x.="Bye" ) );
The solution is, therefore, to use the last form to get it the way you want.
-----------------------------------------------------
Dr. Michael K. Neylon - mneylon-pm@masemware.com
||
"You've left the lens cap of your mind on again, Pinky" - The Brain
It's not what you know, but knowing how to find it if you don't know that's important