in reply to variables / consts for different scripts

I like use constant NAME => 'VALUE';, but this probably doesn't work well with <*.csv>.


daniel.
  • Comment on Re: variables / consts for different scripts

Replies are listed 'Best First'.
Re: Re: variables / consts for different scripts
by Skeeve (Parson) on Aug 28, 2003 at 09:14 UTC
    I thought I like it too.

    But then I found out that it is too complicated to use those constants.

    • They won't interpolate into strings leading to
      print "The file '".FILENAME."' cant't be read";
      instead of
      print "The file '$FILENAME' can't be read";
    • I couldn't find out how to (elegantly) use constants in REs. /IDRE=VALRE/ won't work whereas /$IDRE=$VALRE/o isn't a problem
        /o because the "Variables" are constant and won't change.