However, don't start using prototypes everywhere. They are rarely needed and in many places unneccessary or even wrongly used.
So the main rule is: don't use prototypes unless you certainly know what you are doing. And its use is NOT about checking the type of the sub's parameters.
In all honesty I can say that in all the years I have been programming Perl, I may have used prototypes once or twice only and I'm not entirely sure they were really necessary.
CountZero
A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James
My blog: Imperial DeltronicsIn reply to Re: strange form in sub parameters
by CountZero
in thread strange form in sub parameters
by grasshopper!!!
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |