in reply to How to make global variable, like %ENV

Not to be nosy, but what do you need this for? It's likely that you should use a different approach than creating a package-spanning global. If you tell us what you need it for, maybe someone can suggest a better idea.

Makeshifts last the longest.

  • Comment on Re: How to make global variable, like %ENV

Replies are listed 'Best First'.
Re: Re: How to make global variable, like %ENV
by gmpassos (Priest) on Oct 10, 2002 at 17:52 UTC
    Is for the HWX enverioment. Since the HWX apps can be runed in many packages in the same time, I can't export %HWX to %foo::HWX, because when the app goes out I need to read the hash %HWX to save in the disk, and I can do this if I have a lot of clones of the hash! And I don't want that the user write: %main::HWX, since the hash need to have the idea of a global variable. The changes that I made in the gv.c works very well! What I want is to enable this in other Perl versions, because if someone want to port the resource of HWXperl to other Perl, it will be free to do.

    Graciliano M. P.
    "The creativity is the expression of the liberty".