laziness, impatience, and hubris | |
PerlMonks |
use constant and exporterby Flame (Deacon) |
on Jan 28, 2003 at 03:18 UTC ( [id://230471]=perlquestion: print w/replies, xml ) | Need Help?? |
Flame has asked for the wisdom of the Perl Monks concerning the following question:
According to the constant pragma page, constants declared using the constant pragma, can be exported. The question is, how? I have tried to export them as below, but for some reason it doesn't seem to work.
When I use MyPackage qw(:all); and then attempt to use the VALID, INVALID or ERROR constants, I get error messages saying bareword "VALID" not allowed while "strict subs". Am I doing something wrong here? Thanks My code doesn't have bugs, it just develops random features. Flame ~ Lead Programmer: GMS (DOWN) | GMS (DOWN)
Back to
Seekers of Perl Wisdom
|
|