August 1999 Perl Hardware Store Slide #11

A Module That Exports a Function

         package Foo;
         # Always export `foo':
         sub import {
           # Get name of calling package
           my $caller = caller;  
           *{$caller . '::foo'} = \&foo;
         }


Next Copyright © 1998 M-J. Dominus