I personally have never felt the need. One thing I'll often do is a
foreach(sort keys %hash){
#do something...
}
If you know what the keys are going to be ahead of time that might work
for you.
-----Original Message-----
From: Gavin Bowlby [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 16, 2006 5:37 PM
To: Timothy Johnson; [email protected]
Subject: RE: question on Perl determinism with hash keys
Timothy et al:
Thanks, I did mean in the same order.
Any idea on the relative performance of a hash tied to IxHash vs. a
vanilla hash?
I have a Perl program with many hashes whose entries are created and
destroyed at a high rate, and I'm wondering if I can expect a
performance hit if I make this change...
Gavin
-----Original Message-----
From: Timothy Johnson [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 16, 2006 5:28 PM
To: Gavin Bowlby; [email protected]
Subject: RE: question on Perl determinism with hash keys
If you mean in the same order, then no.
perldoc -q order
-----Original Message-----
From: Gavin Bowlby [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 16, 2006 5:25 PM
To: [email protected]
Subject: question on Perl determinism with hash keys
All:
If I populate a %hash within a Perl program, is there any guarantee that
from run to run of the same Perl program the keys(%hash) function will
return identical sets of keys?
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>