in reply to Re: Getopt::Long to define or not to define?
in thread Getopt::Long to define or not to define?

I've used this behavior to set defaults, but I've more often tested explicitly for undefined and set the default value in code.

True, it's not as lazy as it could be, but it's more consistent for me because I tend to have a block of code that tests all the parameters for sanity, mutual exclusivity and the like right after the call to GetOptions().

It's just my style, I guess.

  • Comment on Re^2: Getopt::Long to define or not to define?