give_me_donations has asked for the wisdom of the Perl Monks concerning the following question:
somewhere else in my 2nd module I have thispackage::config; use exporter; use vars qw (@isa @export @export_ok %export_tags $version); %EXPORT_TAGS = ( sms => [ qw( $SMS_DISABLE_DL %ERRMSG ) ], ); @EXPORT_OK = ( @{ $EXPORT_TAGS{'sms'} }, ); use vars qw( %ERRMSG ); $ERRMSG{123} = "some string error1"; $ERRMSG{345} = "some string error2";
use package::config qw(:sms );
but when I go to mydomain.com/perl-status?package::caller I see it's making a copy of ERRMSG hash I'm trying to use Class::Singleton but I can't figure out, I'll appreciate any help or hints.....what I want to do is when I call the ERRMSG in some other package I want to see it refrenced from it's original package and not make a copy
20050217 Janitored by Corion: Added code tags around code
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: refrencing a hash
by friedo (Prior) on Feb 17, 2005 at 01:15 UTC | |
by give_me_donations (Initiate) on Feb 17, 2005 at 01:21 UTC | |
by give_me_donations (Initiate) on Feb 17, 2005 at 01:36 UTC | |
by friedo (Prior) on Feb 17, 2005 at 01:57 UTC |