Ben Morrow <ben@morrow.me.uk> writes: > Quoth sorourke@ucsd.edu: >> Indeed, if any other slot is defined, *{FOO}{SCALAR} seems to be >> defined. Is this intended behavior? > > Yes. If a glob exists at all it has a SCALAR slot. > >> I am currently using *{FOO}{THING} for everything but scalars, >> and (afterwards) "defined $FOO" for scalars, but it seems like >> there should be a better way. >> [...] > > 'defined $FOO' tells you whether the scalar contains undef or not, not > whether it exists. True. But I think that short of force-upgrading the users of my module to 5.10, this is the best I can do. (It's being used for variable-name completion, fwiw.) By the way, here's a belated "thanks" to whoever wrote the code enabling PERL_DONT_CREATE_GVSV. SeanThread Previous | Thread Next