The constant pragma will take care of this for you
This is true, and I use constants whenever I can, even though interpolating them into strings gets ugly quickly. I suppose that means I value constancy more than elegancy.
The above snippet, however, is a simplification of the Real Word problem, and Anonymonk's suggestion about using prototypes was what I needed to get it straight.
- another intruder with the mooring in the heart of the Perl
In reply to Re^2: Puzzled by constant subs
by grinder
in thread Puzzled by constant subs
by grinder
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |