Well, first, $p::var isn't a global variable; it's a package variable. And p:: does refer to a package; it specifically refers to the package p. So I would reformat your question as follows:
So, I can use $p::var as some arbitrary package variable even under "use strict" and even when "p" doesn't refer to a package that I've specifically declared (i.e., with the "package" keyword)?And the answer is, yes. I suppose you could consider that a deficiency of "use strict".
> Is it an advisable thing to do?Well, personally I would say not. It's bound to confuse someone somewhere. And technically it's allowing you to autovivify a variable, which is what you're trying to avoid by use'ing strict. So I'd avoid it.
In reply to Re: Re: Re: what's $p'a=$a mean?
by Oberon
in thread what's $p'a=$a mean?
by chunlou
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |