|
|
| We don't bite newbies here... much | |
| PerlMonks |
Re: (tye)Re: When to use Prototypes?by demerphq (Chancellor) |
| on Nov 09, 2001 at 22:53 UTC ( #124440=note: print w/ replies, xml ) | Need Help?? |
|
Now I only use prototypes for making compile-time constants and to emulate map's and grep's ability to take bare blocks as code references (and this latter use is quite rare and really only gives a very minor benefit of not having to see "sub" in front of each block). Yeah the bare block trick was what I meant by 'unusual situations' :-) A quick question (which I could answer myself after a bit of testing, but it seems like a point that should be shared) doesn't it also coerce a statement into a block as well? My second question is how do prototypes help you with compile time constants? I assume you are talking about something like and I dont see where prototypes come into play. Am I missing something?
Yves / DeMerphq
In Section
Meditations
|
|
||||||||||||||||||||||||||