in reply to Assign Contains RegEx WTF??
It's just like ($x + $y) * $z. The contents of the parens are evaluated first, and the result is used as the operand of the operation outside the parens.
Scalar assignment returns its LHS as an lvalue, so
is the same as($bname = $fname) =~ s#.*\\##s;
$bname = $fname; $bname =~ s#.*\\##s;
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Assign Contains RegEx WTF??
by eric256 (Parson) on May 21, 2009 at 14:12 UTC |
In Section
Seekers of Perl Wisdom