Others have told you why you get the result you get; here's a couple of ways to get around it:
# this: BEGIN { use vars '$Base'; $Base = 'mybase'; } use constant BASE => $Base; # or this: my $Base = 'mybase'; sub BASE () { $Base }
In reply to Re: Using constants. What am I doing wrong?
by saskaqueer
in thread Using constants. What am I doing wrong?
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |