develooper Front page | perl.perl5.porters | Postings from September 2011

Re: When is a GV not a glob?

Thread Previous | Thread Next
Nicholas Clark
September 12, 2011 13:45
Re: When is a GV not a glob?
Message ID:
On Sun, Sep 11, 2011 at 06:12:03PM -0700, Father Chrysostomos wrote:
> Answer: When it has no GP.
> When does occur? Is it possible to eliminate this exceptional case? (There is code all over the place to deal with it.)

I'm not sure what they are used for now.

They were being used to store PVBMs, but I a month or two ago I "fixed" that
that PVBMs are now stored as PVMGs. They were used in pads, but they don't
seem to be now. (I think that only SVt_PVNVs and SVt_PVMGs are used now)

IIRC they're not used to store stringified globs, thanks to sv_unglob()
being used to convert SVt_PVGV to SVt_PVMG.

I'm not sure *if* there are even exceptional cases now. If there are, it
would be good to eliminate them.

I thought that PVLVs have to be a superclass of PVGVs, as LVALUEs can refer
to globs. Given that LVALUEs have to be able to refer to more regular scalar
types, doesn't this still mean that some glob-related complexity has to
remain, even if it's only for SVt_PVLV

Nicholas Clark

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About