I know I don't need the % prototype, but it helps those who come after me know what the subroutine expects.
That's no reason to use a prototype. That's what comments are for. Perl's prototypes aren't really prototypes at all. It's a great irony that so many people use them under the impression that they are making their code more maintainable because using them without knowing exactly when it is OK to use them will do exactly the opposite.
Prototypes in Perl should be avoided in all but the rarest of cases. See Tom Christiansen's article on them.
-sauoq "My two cents aren't worth a dime.";
In reply to Re: Re: Re: passing subroutine args as a hash: why not?
by sauoq
in thread passing subroutine args as a hash: why not?
by Willard B. Trophy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |