We don't bite newbies here... much | |
PerlMonks |
Re: Re: Perl Programming guidlines/rulesby BUU (Prior) |
on Nov 21, 2002 at 23:48 UTC ( [id://214958]=note: print w/replies, xml ) | Need Help?? |
I support using $_, but you should perhaps implement a standard/guideline in the form of 'Localize $_ in all user created subs', as something like the following: Which looks fairly innocuous in the use of $_ to avoid more temporary vars (It's not an extremely good example, but it serves), but then you do something likemap{foo($_->[0]);$_;} which can return wildly different results then you expected, and lead to many.. interesting.. bugs.
In Section
Meditations
|
|