use MyMod in Perl 5
BEGIN { require MyMod; MyMod->import }
- The parser sees "use MyMod"
- Loads MyMod.pm
- Compiles it
- Runs its import routine
- use is a digression in the caller's compilation
- BEGIN is a powerful but weird tool
- The compiler and the evaluator intermix