package B; foreach $autoload_handled ( 'doit', 'dothis', 'dothat' ) { \&{ $autoload_handled } = \&AUTOLOAD; }