in reply to Re: Question related to the use of constants
in thread Question related to the use of constants

danielcid, just to clarify the parent post a little,

The '=>' operator treats barewords on the left hand side as a string, and CONST1 is a bareword. Changing

CONST1 => 'test1'

to any of the following will work:

(CONST1) => 'test1' # No longer a bareword. CONST1() => 'test1' # constants are really special functions. CONST1, 'test1' # use "," instead of "=>". It's the same, # except it doesn't quote the LHS.