Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
abc.pl #!/usr/bin/perl use lib "."; use A; use B; def(); ######################################## A.pm package A; require Exporter; @ISA = qw(Exporter); @EXPORT = qw( abc ); use B; sub abc{ print "Inside sub abc of package A\n"; } ######################################## B.pm package B; require Exporter; @ISA = qw(Exporter); @EXPORT = qw( def ); use A; sub def{ print "Inside sub def of package B -> calling sub abc from package A\n +"; abc(); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: loading modules using sub
by kennethk (Abbot) on Jun 24, 2010 at 18:38 UTC | |
by Anonymous Monk on Jun 25, 2010 at 06:21 UTC |