|
|
| Problems? Is your data what you think it is? | |
| PerlMonks |
Re^4: shift vs @_by radiantmatrix (Parson) |
| on Oct 06, 2006 at 12:36 UTC ( [id://576706]=note: print w/replies, xml ) | Need Help?? |
This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.
But it doesn't prevent me from being human and making a mistake. Ok, firstly, you said that you can't easily do what you wanted, not that it was easy to make a mistake. Secondly, attempting my $x, $y = @_ with strict in place (which is best practice anyhow) produces: Which would be a pretty big clue to me that something was wrong (you aren't creating a lexical $y with my $x, $y). Doing the same thing with warnings turned on (another best practice) results in:
I'd say that pretty well prevents you from making this mistake, anyhow.
<–radiant.matrix–>
A collection of thoughts and links from the minds of geeks The Code that can be seen is not the true Code I haven't found a problem yet that can't be solved by a well-placed trebuchet
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||||||||