in reply to use Data::DRef qw( :leaf );

use the Exporter module and declare sets of stuff you want to export in an %EXPORT_TAGS hash, like this:
package Foo; use strict; use vars qw(@ISA @EXPORT %EXPORT_TAGS); use Exporter; @ISA = qw(Exporter); %EXPORT_TAGS = ( TAG1 => [qw(F1 F2 Func)], TAG2 => [qw(%bar @baz)], );
now you can:
use Foo qw(:TAG1 %baz);
to import all symbols in TAG1 and %baz.

Replies are listed 'Best First'.
RE: Re: use Data::DRef qw( :leaf );
by reptile (Monk) on May 16, 2000 at 20:21 UTC

    You can also use @EXPORT and @EXPORT_OK; @EXPORT exports what you assign to it every time, and @EXPORT_OK means it's ok to export something, but you have to specify it explicitly to import it.

    Just look at the Exporter manpage, it's got all you ever wanted to know.