in reply to scope of my $x in if statements
and if you REALLY need to modify $x inside g():if( my $x = $_ = f() and g($_) ) {....}
Update: While I agree with ikegami's assessment below that this is not good practice, I maintain that this IS a solution to the problem posted by the O.P.if($_ = \(my $x = f()) and $$_ and g($$_) )
..to maintain is to slowly feel your soul, sanity and sentience ebb away as you become one with the Evil.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: scope of my $x in if statements
by ikegami (Patriarch) on May 07, 2009 at 22:21 UTC |