This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Document string- and number-specific bitops in perlop
[perl5.git] / dist / Storable / t / downgrade.t
1 #!./perl -w
2 #
3 #  Copyright 2002, Larry Wall.
4 #
5 #  You may redistribute only under the same terms as Perl 5, as specified
6 #  in the README file that comes with the distribution.
7 #
8
9 # I ought to keep this test easily backwards compatible to 5.004, so no
10 # qr//;
11
12 # This test checks downgrade behaviour on pre-5.8 perls when new 5.8 features
13 # are encountered.
14
15 sub BEGIN {
16     unshift @INC, 't';
17     unshift @INC, 't/compat' if $] < 5.006002;
18     require Config; import Config;
19     if ($ENV{PERL_CORE} and $Config{'extensions'} !~ /\bStorable\b/) {
20         print "1..0 # Skip: Storable was not built\n";
21         exit 0;
22     }
23 }
24
25 use Test::More;
26 use Storable 'thaw';
27
28 use strict;
29 use vars qw(@RESTRICT_TESTS %R_HASH %U_HASH $UTF8_CROAK $RESTRICTED_CROAK);
30
31 @RESTRICT_TESTS = ('Locked hash', 'Locked hash placeholder',
32                    'Locked keys', 'Locked keys placeholder',
33                   );
34 %R_HASH = (perl => 'rules');
35
36 if ($] > 5.007002) {
37   # This is cheating. "\xdf" in Latin 1 is beta S, so will match \w if it
38   # is stored in utf8, not bytes.
39   # "\xdf" is y diaresis in EBCDIC (except for cp875, but so far no-one seems
40   # to use that) which has exactly the same properties for \w
41   # So the tests happen to pass.
42   my $utf8 = "Schlo\xdf" . chr 256;
43   chop $utf8;
44
45   # \xe5 is V in EBCDIC. That doesn't have the same properties w.r.t. \w as
46   # an a circumflex, so we need to be explicit.
47
48   # and its these very properties we're trying to test - an edge case
49   # involving whether scalars are being stored in bytes or in utf8.
50   my $a_circumflex = (ord ('A') == 193 ? "\x47" : "\xe5");
51   %U_HASH = (map {$_, $_} 'castle', "ch${a_circumflex}teau", $utf8, chr 0x57CE);
52   plan tests => 169;
53 } elsif ($] >= 5.006) {
54   plan tests => 59;
55 } else {
56   plan tests => 67;
57 }
58
59 $UTF8_CROAK = "/^Cannot retrieve UTF8 data in non-UTF8 perl/";
60 $RESTRICTED_CROAK = "/^Cannot retrieve restricted hash/";
61
62 my %tests;
63 {
64   local $/ = "\n\nend\n";
65   while (<DATA>) {
66     next unless /\S/s;
67     unless (/begin ([0-7]{3}) ([^\n]*)\n(.*)$/s) {
68       s/\n.*//s;
69       warn "Dodgy data in section starting '$_'";
70       next;
71     }
72     next unless oct $1 == ord 'A'; # Skip ASCII on EBCDIC, and vice versa
73     my $data = unpack 'u', $3;
74     $tests{$2} = $data;
75   }
76 }
77
78 # use Data::Dumper; $Data::Dumper::Useqq = 1; print Dumper \%tests;
79 sub thaw_hash {
80   my ($name, $expected) = @_;
81   my $hash = eval {thaw $tests{$name}};
82   is ($@, '', "Thawed $name without error?");
83   isa_ok ($hash, 'HASH');
84   ok (defined $hash && eq_hash($hash, $expected),
85       "And it is the hash we expected?");
86   $hash;
87 }
88
89 sub thaw_scalar {
90   my ($name, $expected, $bug) = @_;
91   my $scalar = eval {thaw $tests{$name}};
92   is ($@, '', "Thawed $name without error?");
93   isa_ok ($scalar, 'SCALAR', "Thawed $name?");
94   if ($bug and $] == 5.006) {
95     # Aargh. <expletive> <expletive> 5.6.0's harness doesn't even honour
96     # TODO tests.
97     warn "# Test skipped because eq is buggy for certain Unicode cases in 5.6.0";
98     warn "# Please upgrade to 5.6.1\n";
99     ok ("I'd really like to fail this test on 5.6.0 but I'm told that CPAN auto-dependencies mess up, and certain vendors only ship 5.6.0. Get your vendor to ugrade. Else upgrade your vendor.");
100     # One such vendor being the folks who brought you LONG_MIN as a positive
101     # integer.
102   } else {
103     is ($$scalar, $expected, "And it is the data we expected?");
104   }
105   $scalar;
106 }
107
108 sub thaw_fail {
109   my ($name, $expected) = @_;
110   my $thing = eval {thaw $tests{$name}};
111   is ($thing, undef, "Thawed $name failed as expected?");
112   like ($@, $expected, "Error as predicted?");
113 }
114
115 sub test_locked_hash {
116   my $hash = shift;
117   my @keys = keys %$hash;
118   my ($key, $value) = each %$hash;
119   eval {$hash->{$key} = reverse $value};
120   like( $@, "/^Modification of a read-only value attempted/",
121         'trying to change a locked key' );
122   is ($hash->{$key}, $value, "hash should not change?");
123   eval {$hash->{use} = 'perl'};
124   like( $@, "/^Attempt to access disallowed key 'use' in a restricted hash/",
125         'trying to add another key' );
126   ok (eq_array([keys %$hash], \@keys), "Still the same keys?");
127 }
128
129 sub test_restricted_hash {
130   my $hash = shift;
131   my @keys = keys %$hash;
132   my ($key, $value) = each %$hash;
133   eval {$hash->{$key} = reverse $value};
134   is( $@, '',
135         'trying to change a restricted key' );
136   is ($hash->{$key}, reverse ($value), "hash should change");
137   eval {$hash->{use} = 'perl'};
138   like( $@, "/^Attempt to access disallowed key 'use' in a restricted hash/",
139         'trying to add another key' );
140   ok (eq_array([keys %$hash], \@keys), "Still the same keys?");
141 }
142
143 sub test_placeholder {
144   my $hash = shift;
145   eval {$hash->{rules} = 42};
146   is ($@, '', 'No errors');
147   is ($hash->{rules}, 42, "New value added");
148 }
149
150 sub test_newkey {
151   my $hash = shift;
152   eval {$hash->{nms} = "http://nms-cgi.sourceforge.net/"};
153   is ($@, '', 'No errors');
154   is ($hash->{nms}, "http://nms-cgi.sourceforge.net/", "New value added");
155 }
156
157 # $Storable::DEBUGME = 1;
158 thaw_hash ('Hash with utf8 flag but no utf8 keys', \%R_HASH);
159
160 if (eval "use Hash::Util; 1") {
161   print "# We have Hash::Util, so test that the restricted hashes in <DATA> are valid\n";
162   for $Storable::downgrade_restricted (0, 1, undef, "cheese") {
163     my $hash = thaw_hash ('Locked hash', \%R_HASH);
164     test_locked_hash ($hash);
165     $hash = thaw_hash ('Locked hash placeholder', \%R_HASH);
166     test_locked_hash ($hash);
167     test_placeholder ($hash);
168
169     $hash = thaw_hash ('Locked keys', \%R_HASH);
170     test_restricted_hash ($hash);
171     $hash = thaw_hash ('Locked keys placeholder', \%R_HASH);
172     test_restricted_hash ($hash);
173     test_placeholder ($hash);
174   }
175 } else {
176   print "# We don't have Hash::Util, so test that the restricted hashes downgrade\n";
177   my $hash = thaw_hash ('Locked hash', \%R_HASH);
178   test_newkey ($hash);
179   $hash = thaw_hash ('Locked hash placeholder', \%R_HASH);
180   test_newkey ($hash);
181   $hash = thaw_hash ('Locked keys', \%R_HASH);
182   test_newkey ($hash);
183   $hash = thaw_hash ('Locked keys placeholder', \%R_HASH);
184   test_newkey ($hash);
185   local $Storable::downgrade_restricted = 0;
186   thaw_fail ('Locked hash', $RESTRICTED_CROAK);
187   thaw_fail ('Locked hash placeholder', $RESTRICTED_CROAK);
188   thaw_fail ('Locked keys', $RESTRICTED_CROAK);
189   thaw_fail ('Locked keys placeholder', $RESTRICTED_CROAK);
190 }
191
192 if ($] >= 5.006) {
193   print "# We have utf8 scalars, so test that the utf8 scalars in <DATA> are valid\n";
194   thaw_scalar ('Short 8 bit utf8 data', "\xDF", 1);
195   thaw_scalar ('Long 8 bit utf8 data', "\xDF" x 256, 1);
196   thaw_scalar ('Short 24 bit utf8 data', chr 0xC0FFEE);
197   thaw_scalar ('Long 24 bit utf8 data', chr (0xC0FFEE) x 256);
198 } else {
199   print "# We don't have utf8 scalars, so test that the utf8 scalars downgrade\n";
200   thaw_fail ('Short 8 bit utf8 data', $UTF8_CROAK);
201   thaw_fail ('Long 8 bit utf8 data', $UTF8_CROAK);
202   thaw_fail ('Short 24 bit utf8 data', $UTF8_CROAK);
203   thaw_fail ('Long 24 bit utf8 data', $UTF8_CROAK);
204   local $Storable::drop_utf8 = 1;
205   my $bytes = thaw $tests{'Short 8 bit utf8 data as bytes'};
206   thaw_scalar ('Short 8 bit utf8 data', $$bytes);
207   thaw_scalar ('Long 8 bit utf8 data', $$bytes x 256);
208   $bytes = thaw $tests{'Short 24 bit utf8 data as bytes'};
209   thaw_scalar ('Short 24 bit utf8 data', $$bytes);
210   thaw_scalar ('Long 24 bit utf8 data', $$bytes x 256);
211 }
212
213 if ($] > 5.007002) {
214   print "# We have utf8 hashes, so test that the utf8 hashes in <DATA> are valid\n";
215   my $hash = thaw_hash ('Hash with utf8 keys', \%U_HASH);
216   my $a_circumflex = (ord ('A') == 193 ? "\x47" : "\xe5");
217   for (keys %$hash) {
218     my $l = 0 + /^\w+$/;
219     my $r = 0 + $hash->{$_} =~ /^\w+$/;
220     cmp_ok ($l, '==', $r, sprintf "key length %d", length $_);
221     cmp_ok ($l, '==', $_ eq "ch${a_circumflex}teau" ? 0 : 1);
222   }
223   if (eval "use Hash::Util; 1") {
224     print "# We have Hash::Util, so test that the restricted utf8 hash is valid\n";
225   my $hash = thaw_hash ('Locked hash with utf8 keys', \%U_HASH);
226     for (keys %$hash) {
227       my $l = 0 + /^\w+$/;
228       my $r = 0 + $hash->{$_} =~ /^\w+$/;
229       cmp_ok ($l, '==', $r, sprintf "key length %d", length $_);
230       cmp_ok ($l, '==', $_ eq "ch${a_circumflex}teau" ? 0 : 1);
231     }
232     test_locked_hash ($hash);
233   } else {
234     print "# We don't have Hash::Util, so test that the utf8 hash downgrades\n";
235     fail ("You can't get here [perl version $]]. This is a bug in the test.
236 # Please send the output of perl -V to perlbug\@perl.org");
237   }
238 } else {
239   print "# We don't have utf8 hashes, so test that the utf8 hashes downgrade\n";
240   thaw_fail ('Hash with utf8 keys', $UTF8_CROAK);
241   thaw_fail ('Locked hash with utf8 keys', $UTF8_CROAK);
242   local $Storable::drop_utf8 = 1;
243   my $what = $] < 5.006 ? 'pre 5.6' : '5.6';
244   my $expect = thaw $tests{"Hash with utf8 keys for $what"};
245   thaw_hash ('Hash with utf8 keys', $expect);
246   #foreach (keys %$expect) { print "'$_':\t'$expect->{$_}'\n"; }
247   #foreach (keys %$got) { print "'$_':\t'$got->{$_}'\n"; }
248   if (eval "use Hash::Util; 1") {
249     print "# We have Hash::Util, so test that the restricted hashes in <DATA> are valid\n";
250     fail ("You can't get here [perl version $]]. This is a bug in the test.
251 # Please send the output of perl -V to perlbug\@perl.org");
252   } else {
253     print "# We don't have Hash::Util, so test that the restricted hashes downgrade\n";
254     my $hash = thaw_hash ('Locked hash with utf8 keys', $expect);
255     test_newkey ($hash);
256     local $Storable::downgrade_restricted = 0;
257     thaw_fail ('Locked hash with utf8 keys', $RESTRICTED_CROAK);
258     # Which croak comes first is a bit of an implementation issue :-)
259     local $Storable::drop_utf8 = 0;
260     thaw_fail ('Locked hash with utf8 keys', $RESTRICTED_CROAK);
261   }
262 }
263 __END__
264 # A whole run of 2.x nfreeze data, uuencoded. The "mode bits" are the octal
265 # value of 'A', the "file name" is the test name. Use make_downgrade.pl to
266 # generate these.
267 begin 101 Locked hash
268 8!049`0````$*!7)U;&5S!`````1P97)L
269
270 end
271
272 begin 101 Locked hash placeholder
273 C!049`0````(*!7)U;&5S!`````1P97)L#A0````%<G5L97,`
274
275 end
276
277 begin 101 Locked keys
278 8!049`0````$*!7)U;&5S``````1P97)L
279
280 end
281
282 begin 101 Locked keys placeholder
283 C!049`0````(*!7)U;&5S``````1P97)L#A0````%<G5L97,`
284
285 end
286
287 begin 101 Short 8 bit utf8 data
288 &!047`L.?
289
290 end
291
292 begin 101 Short 8 bit utf8 data as bytes
293 &!04*`L.?
294
295 end
296
297 begin 101 Long 8 bit utf8 data
298 M!048```"`,.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?
299 MPY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#
300 MG\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?
301 MPY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#
302 MG\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?
303 MPY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#
304 MG\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?
305 MPY_#G\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OZ[XL(^_KOBPC[^N^+"/
349 MOZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/
350 MOZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/
351 MOZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/
352 ;OZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N
353
354 end
355
356 begin 101 Hash with utf8 flag but no utf8 keys
357 8!049``````$*!7)U;&5S``````1P97)L
358
359 end
360
361 begin 101 Hash with utf8 keys
362 M!049``````0*!F-A<W1L90`````&8V%S=&QE"@=C:.5T96%U``````=C:.5T
363 D96%U%P/EGXX!`````^6?CA<'4V-H;&_#GP(````&4V-H;&_?
364
365 end
366
367 begin 101 Locked hash with utf8 keys
368 M!049`0````0*!F-A<W1L900````&8V%S=&QE"@=C:.5T96%U!`````=C:.5T
369 D96%U%P/EGXX%`````^6?CA<'4V-H;&_#GP8````&4V-H;&_?
370
371 end
372
373 begin 101 Hash with utf8 keys for pre 5.6
374 M!049``````0*!F-A<W1L90`````&8V%S=&QE"@=C:.5T96%U``````=C:.5T
375 D96%U"@/EGXX``````^6?C@H'4V-H;&_#GP(````&4V-H;&_?
376
377 end
378
379 begin 101 Hash with utf8 keys for 5.6
380 M!049``````0*!F-A<W1L90`````&8V%S=&QE"@=C:.5T96%U``````=C:.5T
381 D96%U%P/EGXX``````^6?CA<'4V-H;&_#GP(````&4V-H;&_?
382
383 end
384
385 begin 301 Locked hash
386 8!049`0````$*!9FDDX6B!`````27A9F3
387
388 end
389
390 begin 301 Locked hash placeholder
391 C!049`0````(.%`````69I).%H@H%F:23A:($````!)>%F9,`
392
393 end
394
395 begin 301 Locked keys
396 8!049`0````$*!9FDDX6B``````27A9F3
397
398 end
399
400 begin 301 Locked keys placeholder
401 C!049`0````(.%`````69I).%H@H%F:23A:(`````!)>%F9,`
402
403 end
404
405 begin 301 Short 8 bit utf8 data
406 &!047`HMS
407
408 end
409
410 begin 301 Short 8 bit utf8 data as bytes
411 &!04*`HMS
412
413 end
414
415 begin 301 Long 8 bit utf8 data
416 M!048```"`(MSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
417 MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
418 M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
419 MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
420 M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
421 MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
422 M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
423 MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
424 M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
425 MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
426 M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
427 8BW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
428
429 end
430
431 begin 301 Short 24 bit utf8 data
432 *!047!OM30G-S50``
433
434 end
435
436 begin 301 Short 24 bit utf8 data as bytes
437 *!04*!OM30G-S50``
438
439 end
440
441 begin 301 Long 24 bit utf8 data
442 M!048```&`/M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
443 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
444 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
445 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
446 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
447 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
448 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
449 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
450 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
451 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
452 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
453 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
454 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
455 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
456 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
457 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
458 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
459 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
460 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
461 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
462 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
463 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
464 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
465 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
466 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
467 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
468 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
469 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
470 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
471 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
472 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
473 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
474 M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
475 M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
476 -5?M30G-S5?M30G-S50``
477
478 end
479
480 begin 301 Hash with utf8 flag but no utf8 keys
481 8!049``````$*!9FDDX6B``````27A9F3
482
483 end
484
485 begin 301 Hash with utf8 keys
486 M!049``````0*!X.(1Z.%@:0`````!X.(1Z.%@:0*!H.!HJ.3A0`````&@X&B
487 FHY.%%P3<9')5`0````3<9')5%P?B@XB3EHMS`@````;B@XB3EM\`
488
489 end
490
491 begin 301 Locked hash with utf8 keys
492 M!049`0````0*!X.(1Z.%@:0$````!X.(1Z.%@:0*!H.!HJ.3A00````&@X&B
493 FHY.%%P3<9')5!0````3<9')5%P?B@XB3EHMS!@````;B@XB3EM\`
494
495 end
496
497 begin 301 Hash with utf8 keys for pre 5.6
498 M!049``````0*!H.!HJ.3A0`````&@X&BHY.%"@B#B(M&HX6!I``````'@XA'
499 GHX6!I`H'XH.(DY:+<P(````&XH.(DY;?"@3<9')5``````3<9')5
500
501 end
502
503 begin 301 Hash with utf8 keys for 5.6
504 M!049``````0*!H.!HJ.3A0`````&@X&BHY.%"@>#B$>CA8&D``````>#B$>C
505 FA8&D%P?B@XB3EHMS`@````;B@XB3EM\7!-QD<E4`````!-QD<E4`
506
507 end