in reply to Understanding order of module compilation and execution
You can arrange for your initialisation to occur in a specific order, by the use of BEGIN blocks within the modules and careful arrangement of the ordering of the use statements in the calling code. Basically, BEGIN blocks are called in the order they are seen, so if both A.pm & B.pm have BEGIN blocks, they will get called in whichever order their use statements appear in script.pl.
See Perlmod for the nitty gritty details.
|
|---|