> Wiggins d Anconia wrote:

[snip]

> > 
> > my $thawed = retrieve('somefile');
> > tie my(%realhash), 'Hash::Case::Lower', $thawed;
> 
> Ah, I guess I'd missed that part in the docs for the Hash::Case::Lower
module. Is it safe 
> to 'delete $thawed' after I tie the hash so I don't have an extra copy
of the hash 
> floating around?
> 

Try and see. A look at the source suggests there isn't a problem doing
it, if there is I would think it is an implementation bug.  I assume by
"delete" you mean allow the variable to go out of scope or otherwise get
garbage collected, as opposed to 'delete' as in -f.

You may also want to consider that nested hashes (if my understanding
and glance at the code are correct) are not necessarily lower case. 
This might be either a suggested improvement, or even a new subclass of
Tie::Hash, aka Tie::Hash::LowerDeep or similar, essentially you would
end up with a nested call to tieing any internal hash refs.

http://danconia.org

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to