This looks fine. However, let's look at this quote from perlsub:use constant DEBUG => 1; use constant SOMETHINGELSE => 'key';
Subroutines whose names are in all upper case are reserved to the Perl
core, as are modules whose names are in all lower case. A subroutine
in all capitals is a loosely-held convention meaning it will be called
indirectly by the run-time system itself, usually due to a triggered
event. Subroutines that do special, pre-defined things include
"AUTOLOAD", "CLONE", "DESTROY" plus all functions mentioned in perltie
and PerlIO::via.
Now, we all know that constant.pm translates constant names into subroutines... The question is: do we violate Perl conventions by using upper-case constant names? Is that one of those cases where syntactic sugar hurts?
Update: The question has been answered here.
In reply to Constant names come into conflict with Perl style? by dmitri
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |