
Cupidvogel
Novice
Apr 3, 2012, 8:11 AM
Post #1 of 5
(718 views)
|
|
Utility of different named blocks in Perl
|
Can't Post
|
|
Hi, Perl has 5 named blocks that are executed/compiled/run at different times: INIT, BEGIN, UNITCHECK, CHECK and END. While the Perldoc page has a good example differentiating between them, it doesn't address the issues where they might be or should be used. Surely the 5 blocks are there because they serve specific purposes, right? Can someone give a specific example for each block stating how it is required there?
(This post was edited by Cupidvogel on Apr 3, 2012, 9:10 AM)
|