The my keyword declares variables. You have to declare a variable before you use it (under use strict), otherwise you'll get the Global symbol "$VERBOSE" requires explicit package name at .. type of message. But you can't re-declare a variable, otherwise you'll get the "my" variable $DEBUG masks earlier declaration in same scope .. type of message.
Define a variable just once, and before it's needed, then Perl won't (or shouldn't) complain.
In reply to Re: "my" variables masking earlier declaration
by talexb
in thread "my" variables masking earlier declaration
by pinkybrown
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |