develooper Front page | perl.beginners | Postings from January 2002

Dumb hash question.

Dean Theophilou
January 3, 2002 18:02
Dumb hash question.
Message ID:

	I was wondering...I want to create (and later modify) a share with
Win32::NetResource module.  My question is: does the SHAREINFO hash structure
need to be completely filled in (or at least initialized) before I use it, or
can I just use only the key/value pairs that will be set?  What I'm really
looking for is a general rule, so please let me know if the above question
results in an answer that is an exception to such a general rule.

	The reason I'm asking is that I've seen Perl examples where all the keys in a
hash were neither used nor initialized and yet a reference to that hash is
passed in as a parameter in another function; whereas I ALWAYS initialize ALL
variables that I use in my scripts.  Anyway, thanks in advance.

Dean Theophilou
Genisar Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About