How do I group my package imports into a single custom package?
Posted
by pavun_cool
on Stack Overflow
See other posts from Stack Overflow
or by pavun_cool
Published on 2010-03-18T06:06:26Z
Indexed on
2010/03/18
6:51 UTC
Read the original article
Hit count: 121
Hi All..
Normally when I am writing the perl program . I used to include following package .
use strict ;
use warnings ;
use Data::Dumper ;
Now , I want like this, I will not include all this package for every program . for that
I will have these all package in my own package. like following.
my_packages.pm
package my_packages ;
{
use strict ;
use warnings ;
use Data::Dumper;
}
1;
So, that if I add my_packages.pm in perl program , it needs have all above packages .
Actually I have done this experimentation . But I am not able get this things . which means when I am using my_packages . I am not able get the functionality of "use strict, use warnings , use Data::Dumper ".
Someone help me out of this problem.....
© Stack Overflow or respective owner