|
|
| P is for Practical | |
| PerlMonks |
Re: Re: Less-than-helpful warningsby ysth (Canon) |
| on Dec 11, 2003 at 03:33 UTC ( #313957=note: print w/ replies, xml ) | Need Help?? |
|
Certainly not if $a and $b are lexical, which in this case they are. I'm not even seeing any problem if they are global. Did perl have a problem at some point where the previous values didn't get restored after the sort? Update: Sorry, I misunderstood that you were warning against using a sort BLOCK in the lexical scope of $a or $b. If you try, perl will die with an error "Can't use "my $[ab]" in sort comparison".
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||