<?xml version="1.0" encoding="windows-1252"?>
<node id="1006737" title="Re^6: Hash order randomization is coming, are you ready?" created="2012-12-02 12:41:31" updated="2012-12-02 12:41:31">
<type id="11">
note</type>
<author id="171588">
BrowserUk</author>
<data>
<field name="doctext">
&lt;blockquote&gt;&lt;i&gt;&lt;/i&gt;&lt;/blockquote&gt;

&lt;p&gt;First, thanks for the clarification.


&lt;p&gt;However, as far as I can tell, what you are saying comes down to:

&lt;blockquote&gt;
Two hashes containing identical keys and values, will iterate in different orders, unless they were constructed in exactly the same way.

&lt;P&gt;For example:&lt;code&gt;
$h1{ $_ } = 1 for         'a'..'z';;
$h2{ $_ } = 1 for reverse 'a'..'z';;

print %h1; print %h2;;

w 1 r 1 a 1 x 1 d 1 j 1 y 1 u 1 k 1 h 1 g 1 f 1 t 1 i 1 e 1 n 1 v 1 m 1 s 1 l 1 c 1 p 1 q 1 b 1 z 1 o 1
w 1 a 1 r 1 d 1 x 1 j 1 y 1 u 1 h 1 k 1 g 1 f 1 i 1 t 1 e 1 n 1 v 1 m 1 s 1 l 1 c 1 p 1 b 1 q 1 z 1 o 1
&lt;/code&gt;

&lt;p&gt;And:&lt;code&gt;
@h1{ 'a'..'z', 'A'..'Z' } = (1)x52;;
delete @h1{ 'A'..'Z' };;

@h2{ 'a'..'z' } = (1)x26;;

print %h1; print %h2;;
a 1 d 1 j 1 y 1 u 1 k 1 g 1 t 1 e 1 v 1 s 1 c 1 q 1 b 1 z 1 w 1 r 1 x 1 h 1 f 1 i 1 n 1 m 1 l 1 p 1 o 1
w 1 r 1 a 1 x 1 d 1 j 1 y 1 u 1 k 1 h 1 g 1 f 1 t 1 i 1 e 1 n 1 v 1 m 1 s 1 l 1 c 1 p 1 q 1 b 1 z 1 o 1
&lt;/code&gt;

&lt;p&gt;And:&lt;code&gt;
@h{ 'a'..'z', 'A'..'Z' } = (1)x52;;
delete @h{ 'A'..'Z' };;

%h2 = %h;;

print %h; print %h2;;
a 1 d 1 j 1 y 1 u 1 k 1 g 1 t 1 e 1 v 1 s 1 c 1 q 1 b 1 z 1 w 1 r 1 x 1 h 1 f 1 i 1 n 1 m 1 l 1 p 1 o 1
w 1 r 1 a 1 x 1 d 1 j 1 y 1 u 1 h 1 k 1 g 1 f 1 i 1 t 1 e 1 n 1 m 1 v 1 s 1 l 1 p 1 c 1 q 1 b 1 z 1 o 1
&lt;/code&gt;

&lt;p&gt;In all cases above, two "identical" hashes were arrived at through a different sequence of operations; and that difference in the sequence of construction manifests itself in a different iteration sequence.

&lt;/blockquote&gt;

&lt;h3&gt;But that has always been the case!&lt;/h3&gt;

&lt;P&gt; The above is 5.10; but the same is also true going right back to my involvement with perl: 5.6.1. 

&lt;p&gt;Which makes me wonder whether your meditation isn't a little a) redundant; b) slightly scare mongery?

&lt;p&gt;Please don't take that the wrong way; I'm simply trying to understand exactly what difference(s) the latest changes have actually made?

&lt;div class="pmsig"&gt;&lt;div class="pmsig-171588"&gt;
&lt;hr /&gt;
&lt;font size=1 &gt;
&lt;div&gt;With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'&lt;/div&gt;
&lt;div&gt;Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.&lt;/div&gt;
&lt;div&gt;"Science is about questioning the status quo. Questioning authority". &lt;/div&gt;
&lt;div&gt;In the absence of evidence, opinion is indistinguishable from prejudice.
&lt;p align=right&gt; [http://thebottomline.cpaaustralia.com.au/|RIP Neil Armstrong]&lt;/p&gt;&lt;/div&gt;
&lt;/font&gt;

&lt;/div&gt;&lt;/div&gt;</field>
<field name="root_node">
1005122</field>
<field name="parent_node">
1006689</field>
</data>
</node>
