http://qs321.pair.com?node_id=208279

rir has asked for the wisdom of the Perl Monks concerning the following question:

What is DEFINED? I have seen references connected with tied variables, but no explanation.

Please do not respond about defined.

Replies are listed 'Best First'.
Re: DEFINED?
by Aristotle (Chancellor) on Oct 26, 2002 at 22:05 UTC
    I'd expect that's the tied object method that gets called when you test a tied variable for definedness. Of course, I'm just speculating, but then, your question is vague too. In what context did you see this?

    Makeshifts last the longest.

      Its mentioned in perlfaq4 (or 'perldoc -q defined') but its not mentioned in any of the Tie::* modules documentation, nor in perltie...sounds like a doc patch might be called for...

        Already patched in Perl 5.8.0.

        DEFINED is not.

        After Compline,
        Zaxo

Re: DEFINED?
by @rocks (Scribe) on Oct 27, 2002 at 01:52 UTC
    Your question's context is writen very poorly!  DEFINED could mean so many different things in Perl it's not even funny. Did you mean  DEFINED variables? Please re-phrase your question to be more speicific than just,  DEFINED?. I might be able to help after I know what to help with.

    -@rocks

      I'd say my question was just arcane not poorly stated.

      I was referring to DEFINED as mentioned in some editions of perlfaq4. I spent a lot of time looking. I guess I looked at the wrong version of the docs today. Very frustrating to search with all the false hits on "defined". Blind tries to use it as a magic variable, a la $AUTOLOAD, and as a routine like EXISTS were all fruitless.

      Given that I have no idea what it is/does, and mentioned the connection to tie; I couldn't improve my query much. The first three responses in this thread all got the context of my question so I don't think I was that vague.

      I could have made it clearer that I was referring to a defined part of Perl but most got that anyway, probably from my contrast to "defined".

      From Zaxo's comment I guess it is gone from Perl.

      Thanks for the criticism. For me it's a battle between a tendency to run on, and on, and on, you know, a natural tendency toward verbosity and poor, complex sentence structures and being too brief.

        No problem I meant no offence.

        -@rocks