I'd even nuke the shift. I replace:
sub dosomething{ my $foo = shift; my $bar = shift;
with
sub dosomething{ my ($foo, $bar) = @_;
That gets all the args and their order right up on the first line of the sub, where it's easier to see. I tend to agree with the Linux kernel CodingStyle document when it says that if you have more than 2-3 args there's probably some re-factoring in order. Cutting and pasting your function calls just seems... icky.
In reply to Re: Re: Poor Man's Prototyping?
by edebill
in thread Poor Man's Prototyping?
by tame1
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |